// 文档 https://github.com/hooke007/MPV_lazy/wiki/4_GLSL

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!WIDTH LUMA.w 4 *
//!HEIGHT LUMA.h 4 *
//!COMPONENTS 1
//!BIND LUMA
//!SAVE LANCZOS3
//!DESC [AiUpscale_Fast_4x_Photo_RT] lanczos3

#define FIX(c)		max(abs(c), 1e-5)
#define PI		3.141592653

vec3 weight3(float x)
{
    vec3 s = FIX(2.0 * PI * vec3(x - 1.5, x - 0.5, x + 0.5));
    return sin(s) * sin(s / 3.0) / (s * s);
}

float line_run(float ypos, vec3 xpos1, vec3 xpos2, vec3 linetaps1, vec3 linetaps2)
{
    return float(LUMA_tex(vec2(xpos1.r, ypos))) * linetaps1.r + float(LUMA_tex(vec2(xpos1.g, ypos))) * linetaps2.r + float(LUMA_tex(vec2(xpos1.b, ypos))) * linetaps1.g + float(LUMA_tex(vec2(xpos2.r, ypos))) * linetaps2.g + float(LUMA_tex(vec2(xpos2.g, ypos))) * linetaps1.b + float(LUMA_tex(vec2(xpos2.b, ypos))) * linetaps2.b;
}

vec4 hook()
{
    vec2 pos = LUMA_pos + LUMA_pt * 0.5;
    vec2 f = fract(pos / LUMA_pt);

    vec3 linetaps1 = weight3(0.5 - f.x * 0.5);
    vec3 linetaps2 = weight3(1.0 - f.x * 0.5);
    vec3 columntaps1 = weight3(0.5 - f.y * 0.5);
    vec3 columntaps2 = weight3(1.0 - f.y * 0.5);

    float suml = dot(linetaps1, vec3(1.0)) + dot(linetaps2, vec3(1.0));
    float sumc = dot(columntaps1, vec3(1.0)) + dot(columntaps2, vec3(1.0));
    linetaps1 /= suml;
    linetaps2 /= suml;
    columntaps1 /= sumc;
    columntaps2 /= sumc;

    vec2 xystart = (-2.5 - f) * LUMA_pt + pos;
    vec3 xpos1 = vec3(xystart.x, xystart.x + LUMA_pt.x, xystart.x + LUMA_pt.x * 2.0);
    vec3 xpos2 = vec3(xystart.x + LUMA_pt.x * 3.0, xystart.x + LUMA_pt.x * 4.0, xystart.x + LUMA_pt.x * 5.0);

    return vec4(line_run(xystart.y, xpos1, xpos2, linetaps1, linetaps2) * columntaps1.r + line_run(xystart.y + LUMA_pt.y, xpos1, xpos2, linetaps1, linetaps2) * columntaps2.r + line_run(xystart.y + LUMA_pt.y * 2.0 , xpos1, xpos2, linetaps1, linetaps2) * columntaps1.g + line_run(xystart.y + LUMA_pt.y * 3.0 , xpos1, xpos2, linetaps1, linetaps2) * columntaps2.g + line_run(xystart.y + LUMA_pt.y * 4.0 , xpos1, xpos2, linetaps1, linetaps2) * columntaps1.b + line_run(xystart.y + LUMA_pt.y * 5.0 , xpos1, xpos2, linetaps1, linetaps2) * columntaps2.b, 0, 0, 0);
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND LUMA
//!SAVE FEATURE1
//!DESC [AiUpscale_Fast_4x_Photo_RT] feature map 1

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.056273318827152,0.101188644766808,-0.555750668048859,0.173603564500809);
res += vec4(0.027163995429873,0.002533331513405,-0.034123685210943,-0.043577846139669) * float(LUMA_texOff(vec2(-2,-2)));
res += vec4(0.075207091867924,0.025781452655792,0.063412599265575,0.081454008817673) * float(LUMA_texOff(vec2(-2,-1)));
res += vec4(-0.063584238290787,-0.006029849406332,0.069762535393238,-0.125684782862663) * float(LUMA_texOff(vec2(-2,0)));
res += vec4(0.002847701543942,-0.035675201565027,-0.021282244473696,0.058030102401972) * float(LUMA_texOff(vec2(-2,1)));
res += vec4(-0.057856526225805,0.017929781228304,-0.008249324746430,0.011422592215240) * float(LUMA_texOff(vec2(-2,2)));
res += vec4(0.016643783077598,0.005840926431119,0.035452585667372,0.072565361857414) * float(LUMA_texOff(vec2(-1,-2)));
res += vec4(-0.199662849307060,-0.062315572053194,-0.076770722866058,0.108563564717770) * float(LUMA_texOff(vec2(-1,-1)));
res += vec4(-0.112901695072651,0.106467947363853,0.233125925064087,0.359310001134872) * float(LUMA_texOff(vec2(-1,0)));
res += vec4(0.203384205698967,0.157086938619614,0.300611197948456,-0.005467761773616) * float(LUMA_texOff(vec2(-1,1)));
res += vec4(0.057383421808481,-0.054332599043846,-0.031718712300062,0.062492687255144) * float(LUMA_texOff(vec2(-1,2)));
res += vec4(-0.104666262865067,0.003861817065626,0.033146742731333,-0.146737530827522) * float(LUMA_texOff(vec2(0,-2)));
res += vec4(0.475649237632751,0.693295359611511,-0.018102265894413,-0.032294437289238) * float(LUMA_texOff(vec2(0,-1)));
res += vec4(-0.505006194114685,-1.423231363296509,0.476667761802673,-1.592117071151733) * float(LUMA_texOff(vec2(0,0)));
res += vec4(-0.384541213512421,-0.179917454719543,-0.046950731426477,0.200468719005585) * float(LUMA_texOff(vec2(0,1)));
res += vec4(-0.085099048912525,0.032873284071684,0.082979500293732,-0.122478298842907) * float(LUMA_texOff(vec2(0,2)));
res += vec4(-0.017136514186859,0.039740584790707,0.065609961748123,0.083284735679626) * float(LUMA_texOff(vec2(1,-2)));
res += vec4(-0.042525120079517,-0.064218625426292,0.023709602653980,-0.036296762526035) * float(LUMA_texOff(vec2(1,-1)));
res += vec4(0.599416196346283,-0.062856160104275,0.210477367043495,0.092719450592995) * float(LUMA_texOff(vec2(1,0)));
res += vec4(0.006198890507221,0.098251134157181,0.177109256386757,-0.035483490675688) * float(LUMA_texOff(vec2(1,1)));
res += vec4(0.077467501163483,-0.045272309333086,0.065513849258423,0.035750616341829) * float(LUMA_texOff(vec2(1,2)));
res += vec4(0.033482369035482,-0.046911485493183,-0.011574981734157,0.001167910988443) * float(LUMA_texOff(vec2(2,-2)));
res += vec4(-0.032585415989161,0.126135051250458,-0.167808040976524,0.016759332269430) * float(LUMA_texOff(vec2(2,-1)));
res += vec4(-0.026451407000422,0.004479352850467,0.133262470364571,-0.086441494524479) * float(LUMA_texOff(vec2(2,0)));
res += vec4(0.056841671466827,-0.039045222103596,-0.095332615077496,0.064129091799259) * float(LUMA_texOff(vec2(2,1)));
res += vec4(-0.022492974996567,-0.018269548192620,-0.012330116704106,-0.011194480583072) * float(LUMA_texOff(vec2(2,2)));
res = max(res, vec4(0.0)) + vec4(0.615297555923462,0.139953777194023,0.936189413070679,-0.003462160471827) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.201060339808464,0.115881316363811,0.108349926769733,0.182916745543480);
res += vec4(0.018958766013384,0.024283306673169,0.024946290999651,0.024647030979395) * float(LUMA_texOff(vec2(-2,-2)));
res += vec4(-0.004968339111656,-0.023960504680872,0.118666425347328,0.007498090621084) * float(LUMA_texOff(vec2(-2,-1)));
res += vec4(0.013817436993122,-0.039389126002789,-0.208651244640350,-0.010473325848579) * float(LUMA_texOff(vec2(-2,0)));
res += vec4(-0.089040324091911,0.022918617352843,-0.022710165008903,-0.018739430233836) * float(LUMA_texOff(vec2(-2,1)));
res += vec4(0.013171886093915,0.051963426172733,-0.026761963963509,-0.017275365069509) * float(LUMA_texOff(vec2(-2,2)));
res += vec4(0.033128999173641,-0.056306313723326,-0.262219220399857,0.012350709177554) * float(LUMA_texOff(vec2(-1,-2)));
res += vec4(-0.239101335406303,0.394356578588486,0.189089596271515,-0.112007983028889) * float(LUMA_texOff(vec2(-1,-1)));
res += vec4(0.372511744499207,0.492880374193192,0.065061479806900,0.114783927798271) * float(LUMA_texOff(vec2(-1,0)));
res += vec4(-1.251364350318909,-0.033474609255791,-0.078958295285702,0.015015628188848) * float(LUMA_texOff(vec2(-1,1)));
res += vec4(-0.349044144153595,-0.015822041779757,0.042252425104380,0.013879338279366) * float(LUMA_texOff(vec2(-1,2)));
res += vec4(0.005879315547645,0.014912551268935,0.094354353845119,0.037926100194454) * float(LUMA_texOff(vec2(0,-2)));
res += vec4(0.120954297482967,-0.136390581727028,0.183471009135246,-1.696407198905945) * float(LUMA_texOff(vec2(0,-1)));
res += vec4(-0.011912452057004,-1.303979992866516,-0.637893736362457,0.367808163166046) * float(LUMA_texOff(vec2(0,0)));
res += vec4(0.251059383153915,0.023764034733176,0.074119664728642,-0.148435056209564) * float(LUMA_texOff(vec2(0,1)));
res += vec4(0.044667836278677,-0.065984569489956,-0.214942798018456,0.053729202598333) * float(LUMA_texOff(vec2(0,2)));
res += vec4(-0.022944862022996,-0.012146920897067,0.140658974647522,-0.123724117875099) * float(LUMA_texOff(vec2(1,-2)));
res += vec4(-0.034073151648045,0.089224986732006,-0.378615498542786,0.319483906030655) * float(LUMA_texOff(vec2(1,-1)));
res += vec4(0.134913489222527,-0.109544813632965,0.682823479175568,-0.072180934250355) * float(LUMA_texOff(vec2(1,0)));
res += vec4(-0.159433543682098,0.092117160558701,-0.187486022710800,0.104655019938946) * float(LUMA_texOff(vec2(1,1)));
res += vec4(0.028276355937123,0.004885640926659,0.197363749146461,-0.024395044893026) * float(LUMA_texOff(vec2(1,2)));
res += vec4(0.017786648124456,0.014975099824369,0.071224093437195,0.029397623613477) * float(LUMA_texOff(vec2(2,-2)));
res += vec4(0.005027378909290,-0.045063503086567,0.129401758313179,-0.026700846850872) * float(LUMA_texOff(vec2(2,-1)));
res += vec4(-0.084677673876286,0.023602982982993,-0.116767890751362,0.049906395375729) * float(LUMA_texOff(vec2(2,0)));
res += vec4(0.057862322777510,-0.029862379655242,-0.073414392769337,-0.028126623481512) * float(LUMA_texOff(vec2(2,1)));
res += vec4(0.046173758804798,0.009426387958229,0.050756648182869,0.010048463009298) * float(LUMA_texOff(vec2(2,2)));
res = max(res, vec4(0.0)) + vec4(0.058680459856987,-0.002069689100608,0.877453804016113,-0.025295345112681) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND LUMA
//!SAVE FEATURE2
//!DESC [AiUpscale_Fast_4x_Photo_RT] feature map 2

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.078504383563995,0.057002663612366,-0.625512480735779,-0.134472817182541);
res += vec4(-0.021046325564384,-0.025810392573476,0.031502496451139,-0.004050307907164) * float(LUMA_texOff(vec2(-2,-2)));
res += vec4(0.047962691634893,-0.009099860675633,-0.040298331528902,0.005473906174302) * float(LUMA_texOff(vec2(-2,-1)));
res += vec4(-0.019934680312872,0.151081681251526,0.031929008662701,0.194737970829010) * float(LUMA_texOff(vec2(-2,0)));
res += vec4(0.037141826003790,-0.085165537893772,-0.062282949686050,-0.095989346504211) * float(LUMA_texOff(vec2(-2,1)));
res += vec4(-0.042465686798096,0.005475210491568,0.023322608321905,-0.030192494392395) * float(LUMA_texOff(vec2(-2,2)));
res += vec4(-0.058733701705933,0.104565404355526,-0.091533087193966,-0.090354643762112) * float(LUMA_texOff(vec2(-1,-2)));
res += vec4(0.086045756936073,0.022739373147488,0.177025094628334,-0.127188220620155) * float(LUMA_texOff(vec2(-1,-1)));
res += vec4(-0.042888995260000,0.537339568138123,-0.078739166259766,-0.042569227516651) * float(LUMA_texOff(vec2(-1,0)));
res += vec4(-0.086888276040554,0.207211300730705,-0.019111985340714,0.215914249420166) * float(LUMA_texOff(vec2(-1,1)));
res += vec4(0.012020979076624,-0.015999412164092,-0.026831135153770,-0.089057005941868) * float(LUMA_texOff(vec2(-1,2)));
res += vec4(0.087801836431026,-0.066702879965305,0.177085220813751,0.100191421806812) * float(LUMA_texOff(vec2(0,-2)));
res += vec4(-0.644968211650848,-0.196302756667137,0.864757776260376,-0.144377321004868) * float(LUMA_texOff(vec2(0,-1)));
res += vec4(0.767212212085724,-0.517468810081482,-0.044719908386469,0.966292381286621) * float(LUMA_texOff(vec2(0,0)));
res += vec4(0.175211891531944,-0.034032374620438,0.055242434144020,-0.505902528762817) * float(LUMA_texOff(vec2(0,1)));
res += vec4(-0.014976222999394,-0.048401281237602,-0.006851437501609,0.106032557785511) * float(LUMA_texOff(vec2(0,2)));
res += vec4(-0.017120717093349,-0.004849533084780,-0.072145693004131,-0.105479240417480) * float(LUMA_texOff(vec2(1,-2)));
res += vec4(-0.737245500087738,0.066940404474735,0.036092866212130,0.133228689432144) * float(LUMA_texOff(vec2(1,-1)));
res += vec4(-0.300898373126984,-0.091458640992641,-0.037977602332830,-0.626966357231140) * float(LUMA_texOff(vec2(1,0)));
res += vec4(-0.141611814498901,-0.091086789965630,-0.092139929533005,0.123481549322605) * float(LUMA_texOff(vec2(1,1)));
res += vec4(0.038562141358852,0.079643160104752,0.018193326890469,0.008055059239268) * float(LUMA_texOff(vec2(1,2)));
res += vec4(-0.065879277884960,-0.010242134332657,-0.021820416674018,0.016070589423180) * float(LUMA_texOff(vec2(2,-2)));
res += vec4(0.267976433038712,0.045055467635393,0.070934921503067,0.068162895739079) * float(LUMA_texOff(vec2(2,-1)));
res += vec4(-0.163531735539436,-0.034509759396315,-0.054585989564657,0.153390139341354) * float(LUMA_texOff(vec2(2,0)));
res += vec4(0.076265364885330,0.034100484102964,0.006897381041199,0.030372936278582) * float(LUMA_texOff(vec2(2,1)));
res += vec4(-0.035810153931379,-0.027092555537820,-0.018185073509812,-0.039877183735371) * float(LUMA_texOff(vec2(2,2)));
res = max(res, vec4(0.0)) + vec4(0.050932087004185,-0.345803558826447,0.025258352980018,0.990158498287201) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.010790896601975,0.033184126019478,-0.302218854427338,0.232700571417809);
res += vec4(0.060881402343512,0.052087355405092,-0.051449250429869,-0.038241811096668) * float(LUMA_texOff(vec2(-2,-2)));
res += vec4(0.041422389447689,0.000813650491182,-0.056428350508213,0.033726375550032) * float(LUMA_texOff(vec2(-2,-1)));
res += vec4(-0.005201664753258,0.156333386898041,-0.060256425291300,-0.009449805133045) * float(LUMA_texOff(vec2(-2,0)));
res += vec4(0.110482327640057,-0.122368544340134,0.088626459240913,0.063548617064953) * float(LUMA_texOff(vec2(-2,1)));
res += vec4(-0.127638220787048,0.039210528135300,0.060752019286156,-0.045391526073217) * float(LUMA_texOff(vec2(-2,2)));
res += vec4(-0.034898109734058,-0.143199071288109,0.011944980360568,0.002596700098366) * float(LUMA_texOff(vec2(-1,-2)));
res += vec4(0.078914843499660,0.030131369829178,0.257437199354172,-0.088789850473404) * float(LUMA_texOff(vec2(-1,-1)));
res += vec4(-0.262272566556931,-0.540295243263245,0.110550604760647,-0.899971544742584) * float(LUMA_texOff(vec2(-1,0)));
res += vec4(0.193450018763542,0.108083263039589,-0.037754565477371,-0.184942170977592) * float(LUMA_texOff(vec2(-1,1)));
res += vec4(-0.075191520154476,-0.074755303561687,-0.000992798130028,0.025914965197444) * float(LUMA_texOff(vec2(-1,2)));
res += vec4(-0.064386151731014,0.049170304089785,0.065130829811096,0.023128816857934) * float(LUMA_texOff(vec2(0,-2)));
res += vec4(0.272055864334106,-0.037295058369637,0.424035280942917,0.310405254364014) * float(LUMA_texOff(vec2(0,-1)));
res += vec4(0.469620108604431,0.475168317556381,-0.303339689970016,-0.819135308265686) * float(LUMA_texOff(vec2(0,0)));
res += vec4(-0.567655682563782,-0.067039258778095,0.114360935986042,0.194336757063866) * float(LUMA_texOff(vec2(0,1)));
res += vec4(0.118374682962894,-0.022562373429537,-0.065324589610100,0.034658186137676) * float(LUMA_texOff(vec2(0,2)));
res += vec4(-0.150016173720360,-0.032951094210148,-0.007042633369565,-0.060677044093609) * float(LUMA_texOff(vec2(1,-2)));
res += vec4(-0.331086307764053,-0.155889347195625,0.313438534736633,0.044060721993446) * float(LUMA_texOff(vec2(1,-1)));
res += vec4(0.060043763369322,-0.592007875442505,0.022313166409731,0.051626291126013) * float(LUMA_texOff(vec2(1,0)));
res += vec4(0.065449297428131,0.231757432222366,0.062547825276852,-0.063698790967464) * float(LUMA_texOff(vec2(1,1)));
res += vec4(0.198681220412254,-0.021061655133963,-0.076499812304974,0.010052053257823) * float(LUMA_texOff(vec2(1,2)));
res += vec4(0.117028541862965,0.130712926387787,-0.074666135013103,0.054666232317686) * float(LUMA_texOff(vec2(2,-2)));
res += vec4(-0.103286281228065,0.145044520497322,-0.087674900889397,-0.060323383659124) * float(LUMA_texOff(vec2(2,-1)));
res += vec4(-0.094910390675068,0.439723223447800,-0.076721876859665,0.058280821889639) * float(LUMA_texOff(vec2(2,0)));
res += vec4(0.164530202746391,-0.138126716017723,0.007947210222483,-0.000275519967545) * float(LUMA_texOff(vec2(2,1)));
res += vec4(-0.089278377592564,0.088253967463970,0.009192095138133,0.010923218913376) * float(LUMA_texOff(vec2(2,2)));
res = max(res, vec4(0.0)) + vec4(0.636375248432159,0.609880983829498,0.948702991008759,0.082822464406490) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND LUMA
//!SAVE FEATURE3
//!DESC [AiUpscale_Fast_4x_Photo_RT] feature map 3

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.214371472597122,0.210771456360817,-0.028496472164989,0.034260589629412);
res += vec4(0.016621805727482,-0.046537760645151,0.030785759910941,0.115512460470200) * float(LUMA_texOff(vec2(-2,-2)));
res += vec4(-0.114736400544643,0.082574233412743,0.034374084323645,-0.093795336782932) * float(LUMA_texOff(vec2(-2,-1)));
res += vec4(0.198464363813400,-0.014551840722561,-0.027521412819624,0.019881937652826) * float(LUMA_texOff(vec2(-2,0)));
res += vec4(-0.106535993516445,0.063313260674477,-0.144758194684982,-0.055742595344782) * float(LUMA_texOff(vec2(-2,1)));
res += vec4(0.025339230895042,-0.023705566301942,0.088980726897717,0.007002762518823) * float(LUMA_texOff(vec2(-2,2)));
res += vec4(-0.051037743687630,0.063455052673817,0.023175736889243,-0.139004603028297) * float(LUMA_texOff(vec2(-1,-2)));
res += vec4(0.105778202414513,-0.191837668418884,-0.080408990383148,0.145671948790550) * float(LUMA_texOff(vec2(-1,-1)));
res += vec4(-0.656251072883606,0.126232802867889,0.493386000394821,-0.383655816316605) * float(LUMA_texOff(vec2(-1,0)));
res += vec4(-0.177021607756615,-0.355246067047119,-0.272797942161560,0.386729508638382) * float(LUMA_texOff(vec2(-1,1)));
res += vec4(0.018586909398437,0.123602874577045,0.159408703446388,0.012415806762874) * float(LUMA_texOff(vec2(-1,2)));
res += vec4(-0.004373907111585,-0.033822655677795,0.260719120502472,0.077153928577900) * float(LUMA_texOff(vec2(0,-2)));
res += vec4(0.134554699063301,0.059727348387241,-0.135139375925064,0.181372508406639) * float(LUMA_texOff(vec2(0,-1)));
res += vec4(0.622282505035400,-1.051830053329468,0.117112323641777,-0.409395128488541) * float(LUMA_texOff(vec2(0,0)));
res += vec4(0.268198907375336,-0.478289872407913,-0.009110273793340,0.240898609161377) * float(LUMA_texOff(vec2(0,1)));
res += vec4(-0.018034348264337,0.356687754392624,-0.206141248345375,-0.087946012616158) * float(LUMA_texOff(vec2(0,2)));
res += vec4(-0.006173049099743,-0.049127437174320,0.025830240920186,-0.085728973150253) * float(LUMA_texOff(vec2(1,-2)));
res += vec4(-0.046750385314226,-0.012497260235250,0.007436108309776,-0.126823514699936) * float(LUMA_texOff(vec2(1,-1)));
res += vec4(0.161515936255455,-0.006918907631189,-0.197701945900917,-0.165574878454208) * float(LUMA_texOff(vec2(1,0)));
res += vec4(0.044825755059719,-0.070408046245575,0.151407480239868,0.275458246469498) * float(LUMA_texOff(vec2(1,1)));
res += vec4(-0.046711269766092,0.165143340826035,-0.155265405774117,0.088849492371082) * float(LUMA_texOff(vec2(1,2)));
res += vec4(-0.025580720975995,0.085845381021500,-0.002354226307943,0.050684440881014) * float(LUMA_texOff(vec2(2,-2)));
res += vec4(-0.055997237563133,-0.120084844529629,0.017691086977720,0.028425076976418) * float(LUMA_texOff(vec2(2,-1)));
res += vec4(0.179176941514015,0.140604749321938,-0.042373355478048,-0.026086917147040) * float(LUMA_texOff(vec2(2,0)));
res += vec4(-0.138798117637634,0.074198640882969,-0.094344049692154,-0.072008587419987) * float(LUMA_texOff(vec2(2,1)));
res += vec4(0.011016915552318,-0.053116351366043,0.052598327398300,0.020895043388009) * float(LUMA_texOff(vec2(2,2)));
res = max(res, vec4(0.0)) + vec4(0.758334100246429,-0.008644855581224,0.880831897258759,0.267845153808594) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.508984267711639,0.064886189997196,0.236094355583191,-0.239041775465012);
res += vec4(-0.038210723549128,-0.031784065067768,-0.013998968526721,0.039689451456070) * float(LUMA_texOff(vec2(-2,-2)));
res += vec4(0.039002992212772,0.064142696559429,-0.031395819038153,-0.163525104522705) * float(LUMA_texOff(vec2(-2,-1)));
res += vec4(0.009710656479001,0.045410033315420,0.056522734463215,0.125964209437370) * float(LUMA_texOff(vec2(-2,0)));
res += vec4(-0.024317605420947,-0.071661882102489,-0.048637282103300,-0.027420111000538) * float(LUMA_texOff(vec2(-2,1)));
res += vec4(0.016876118257642,0.025181422010064,0.027512762695551,0.021232109516859) * float(LUMA_texOff(vec2(-2,2)));
res += vec4(0.065561525523663,0.075935602188110,0.067863300442696,-0.083212167024612) * float(LUMA_texOff(vec2(-1,-2)));
res += vec4(0.022500885650516,-0.067632019519806,-0.077070862054825,0.236397340893745) * float(LUMA_texOff(vec2(-1,-1)));
res += vec4(-0.186445206403732,0.474083870649338,-0.071314722299576,-0.579184234142303) * float(LUMA_texOff(vec2(-1,0)));
res += vec4(0.057464763522148,-0.023476565256715,-0.052446577697992,-0.012110047973692) * float(LUMA_texOff(vec2(-1,1)));
res += vec4(0.003893961198628,0.049047745764256,0.043278917670250,-0.004617147147655) * float(LUMA_texOff(vec2(-1,2)));
res += vec4(-0.029405089095235,0.027372287586331,0.009501247666776,0.144716098904610) * float(LUMA_texOff(vec2(0,-2)));
res += vec4(-0.112915702164173,-0.123825661838055,0.192342206835747,-0.244054004549980) * float(LUMA_texOff(vec2(0,-1)));
res += vec4(-0.674403607845306,-0.520698249340057,-0.677599430084229,1.099440217018127) * float(LUMA_texOff(vec2(0,0)));
res += vec4(-0.115636788308620,0.000829843571410,-0.277730882167816,-0.272293537855148) * float(LUMA_texOff(vec2(0,1)));
res += vec4(0.034109838306904,-0.020504925400019,-0.001311575411819,0.036234874278307) * float(LUMA_texOff(vec2(0,2)));
res += vec4(0.026862068101764,-0.040264077484608,-0.033200811594725,-0.002647931687534) * float(LUMA_texOff(vec2(1,-2)));
res += vec4(0.003787852358073,0.053440582007170,-0.044452361762524,0.163745746016502) * float(LUMA_texOff(vec2(1,-1)));
res += vec4(0.174649313092232,0.072032265365124,-0.647418797016144,0.347372740507126) * float(LUMA_texOff(vec2(1,0)));
res += vec4(0.013023931533098,0.072083152830601,-0.122193455696106,-0.000457933492726) * float(LUMA_texOff(vec2(1,1)));
res += vec4(-0.005971351638436,-0.026261625811458,-0.001144742243923,-0.069773420691490) * float(LUMA_texOff(vec2(1,2)));
res += vec4(-0.011305906809866,-0.019225746393204,-0.111498527228832,-0.057954538613558) * float(LUMA_texOff(vec2(2,-2)));
res += vec4(0.031321376562119,0.058484893292189,0.032486449927092,-0.135682120919228) * float(LUMA_texOff(vec2(2,-1)));
res += vec4(-0.052447512745857,-0.108836889266968,-0.080727711319923,-0.027655309066176) * float(LUMA_texOff(vec2(2,0)));
res += vec4(0.034976895898581,0.020925877615809,0.056231260299683,-0.109269060194492) * float(LUMA_texOff(vec2(2,1)));
res += vec4(0.005497104953974,-0.011142961680889,-0.068932361900806,-0.023016901686788) * float(LUMA_texOff(vec2(2,2)));
res = max(res, vec4(0.0)) + vec4(2.577767848968506,-0.461281210184097,0.329996049404144,0.928627431392670) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND FEATURE1
//!BIND FEATURE2
//!BIND FEATURE3
//!SAVE MODEL1
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 1_1

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.057856880128384,-0.102930553257465,-0.635047852993011,0.022708289325237);
res += mat4(0.389894902706146,-0.154278129339218,0.013086761347950,-0.185083284974098,-0.173164695501328,0.438769370317459,0.218829572200775,-0.043930977582932,0.031822133809328,-0.217095822095871,0.131287232041359,-0.076701894402504,0.281723469495773,0.344120383262634,0.151713460683823,0.159812092781067) * FEATURE1_texOff(vec2(-1,-1));
res += mat4(-0.280081152915955,-0.110108286142349,0.376913309097290,-0.351971983909607,0.091191060841084,-0.206224486231804,-0.034180223941803,-0.157192215323448,0.083200223743916,-0.159654706716537,0.028195437043905,-0.027254207059741,0.096443511545658,0.132070302963257,0.015386718325317,0.180310875177383) * FEATURE1_texOff(vec2(-1,0));
res += mat4(-0.324683159589767,0.013748405501246,-0.056380335241556,0.010865365155041,0.205058336257935,-0.001822505029850,0.167995288968086,-0.065624371170998,-0.022158965468407,0.065098769962788,0.062153127044439,0.064166635274887,0.174042314291000,0.051888514310122,0.093531370162964,0.182285398244858) * FEATURE1_texOff(vec2(-1,1));
res += mat4(0.063555270433426,-0.289504826068878,-0.438231199979782,0.053784850984812,-0.107147917151451,-0.341211706399918,0.176792949438095,0.252800464630127,0.062021166086197,-0.363889098167419,-0.089373849332333,-0.039899509400129,-0.029047075659037,-0.010749134235084,0.392158150672913,-0.183972328901291) * FEATURE1_texOff(vec2(0,-1));
res += mat4(-0.013091619126499,-0.409421592950821,-0.130693480372429,0.180234611034393,-0.000673504197039,-0.592638492584229,-0.283537477254868,-0.009956072084606,-0.283658504486084,0.228774353861809,0.413694202899933,-0.312143862247467,-0.028531365096569,-0.075169853866100,-0.089994557201862,0.320082455873489) * FEATURE1_texOff(vec2(0,0));
res += mat4(-0.132043540477753,0.377191066741943,0.107852511107922,-0.105627074837685,-0.338288813829422,0.405022174119949,-0.019319469109178,-0.216732084751129,0.042317874729633,-0.070163235068321,0.051458880305290,0.138142555952072,0.255634337663651,-0.024437163025141,0.266770154237747,-0.104944258928299) * FEATURE1_texOff(vec2(0,1));
res += mat4(-0.096125133335590,0.054609201848507,0.006831963546574,-0.080685734748840,0.007002410944551,-0.246037080883980,0.108872130513191,-0.267857521772385,0.062544248998165,-0.055553030222654,0.265740007162094,-0.097216002643108,-0.052890397608280,-0.046915512531996,0.059704441577196,0.086415730416775) * FEATURE1_texOff(vec2(1,-1));
res += mat4(-0.185542091727257,0.141248360276222,0.106911823153496,0.012537402100861,-0.219525262713432,-0.051792353391647,-0.172941625118256,-0.182751595973969,-0.139802515506744,0.050823759287596,0.397149920463562,-0.112448066473007,-0.123179636895657,0.120347008109093,-0.050199598073959,-0.359209805727005) * FEATURE1_texOff(vec2(1,0));
res += mat4(0.096088938415051,0.082615911960602,-0.040247071534395,0.058335393667221,-0.168855279684067,0.142740696668625,0.135519400238991,0.091676011681557,-0.011189576238394,-0.090629540383816,-0.040600467473269,0.050312083214521,-0.177839353680611,0.117328941822052,0.388571381568909,-0.213262617588043) * FEATURE1_texOff(vec2(1,1));
res += mat4(0.163295984268188,-0.324850797653198,-0.000645474938210,0.117594607174397,0.080781005322933,-0.023180309683084,-0.003200131468475,0.006791223306209,0.067063011229038,-0.067539006471634,-0.434951156377792,-0.072774574160576,-0.183502122759819,-0.099117122590542,-0.037792019546032,0.044310312718153) * FEATURE2_texOff(vec2(-1,-1));
res += mat4(0.061268795281649,0.406578958034515,-0.017518566921353,0.140087425708771,0.002992167137563,-0.186076924204826,0.069843240082264,-0.106685183942318,-0.544558107852936,0.036587178707123,-0.220884978771210,0.335693776607513,0.293036103248596,-0.138933032751083,-0.420057564973831,0.449508011341095) * FEATURE2_texOff(vec2(-1,0));
res += mat4(-0.123200215399265,0.057839833199978,-0.080849818885326,0.323156863451004,0.013805857859552,-0.104305624961853,0.057058569043875,0.031807433813810,-0.085626892745495,-0.268334925174713,-0.312126040458679,0.241581439971924,-0.072231873869896,0.040917918086052,0.021815897896886,0.038778208196163) * FEATURE2_texOff(vec2(-1,1));
res += mat4(-0.018089111894369,-0.048572137951851,0.101441942155361,-0.082023240625858,-0.169203698635101,-0.271358489990234,0.159831359982491,-0.063561186194420,0.167273446917534,-0.054452851414680,-0.159503057599068,-0.166714265942574,0.506872713565826,-0.238563522696495,-0.562438726425171,0.190943449735641) * FEATURE2_texOff(vec2(0,-1));
res += mat4(-0.230944395065308,0.347893297672272,0.087037041783333,-0.018081327900290,0.348542571067810,-0.130965366959572,-0.270550280809402,0.076702199876308,0.044803641736507,0.023515980690718,-0.037332527339458,-0.285805970430374,-0.309561043977737,0.424223452806473,0.637321531772614,-0.697789430618286) * FEATURE2_texOff(vec2(0,0));
res += mat4(0.005552594084293,-0.028864189982414,-0.002547180978581,0.199923932552338,0.026820080354810,0.134490162134171,-0.085800796747208,-0.112622059881687,-0.231272354722023,-0.016148148104548,0.534388303756714,-0.106320254504681,-0.047886349260807,-0.067475162446499,0.215544417500496,0.054307579994202) * FEATURE2_texOff(vec2(0,1));
res += mat4(-0.023732006549835,-0.017754539847374,0.170587554574013,-0.169519677758217,-0.085913822054863,0.024326154962182,0.047970611602068,0.034951061010361,-0.015904953703284,0.041037295013666,-0.145232781767845,0.061826031655073,0.096481576561928,0.016994474455714,0.011156310327351,-0.155828773975372) * FEATURE2_texOff(vec2(1,-1));
res += mat4(-0.105264142155647,0.001397072570398,0.068291202187538,0.092856653034687,0.443525522947311,0.175928056240082,-0.293011754751205,-0.008256517350674,0.170922875404358,0.101660750806332,-0.105158977210522,-0.152728706598282,-0.101918309926987,0.086497001349926,0.212573006749153,-0.058232560753822) * FEATURE2_texOff(vec2(1,0));
res += mat4(-0.048714712262154,0.022450270131230,0.126329869031906,0.016477707773447,-0.107444845139980,0.183403417468071,-0.047720789909363,-0.012685555964708,0.255811452865601,0.297536969184875,-0.034598387777805,0.038998514413834,-0.023875216022134,0.128486335277557,0.072408944368362,0.084655933082104) * FEATURE2_texOff(vec2(1,1));
res += mat4(-0.094719834625721,-0.135388195514679,-0.063446693122387,0.014865640550852,-0.085840538144112,-0.089268378913403,0.028952987864614,0.105111151933670,-0.047820944339037,0.002244074363261,-0.192993238568306,0.061497971415520,0.235723778605461,-0.251890867948532,-0.083336614072323,0.114244498312473) * FEATURE3_texOff(vec2(-1,-1));
res += mat4(0.149490252137184,0.011708883568645,0.173292323946953,0.079294957220554,-0.004477857146412,-0.022955898195505,0.163063704967499,0.008397608064115,0.050284516066313,0.131952613592148,-0.011628541164100,0.074093893170357,0.017920583486557,0.320588409900665,-0.258941769599915,0.091505423188210) * FEATURE3_texOff(vec2(-1,0));
res += mat4(-0.063451193273067,0.007932318374515,0.078944079577923,-0.178092554211617,-0.136034920811653,-0.069698490202427,0.150340482592583,-0.112555801868439,-0.219742462038994,0.134820312261581,-0.054869666695595,0.107242271304131,-0.294105619192123,0.129558876156807,0.023283809423447,0.049204699695110) * FEATURE3_texOff(vec2(-1,1));
res += mat4(0.399122655391693,0.141047805547714,0.126045823097229,-0.157233566045761,-0.216060265898705,0.286792844533920,-0.052104625850916,0.363064348697662,0.129297584295273,-0.177155926823616,0.209861308336258,-0.060980156064034,0.059370931237936,0.043312124907970,0.158846631646156,-0.078321911394596) * FEATURE3_texOff(vec2(0,-1));
res += mat4(-0.142626449465752,0.494081050157547,0.526245176792145,-0.309996455907822,-0.261641860008240,-0.002587167313322,-0.003275621915236,0.122478514909744,0.266438245773315,-0.206104964017868,0.192219793796539,0.135565415024757,0.094607330858707,-0.011520574800670,-0.062364496290684,0.000852809986100) * FEATURE3_texOff(vec2(0,0));
res += mat4(-0.067201875150204,0.299960494041443,0.022517377510667,0.054208993911743,-0.062590502202511,0.119050018489361,0.057146143168211,-0.052790857851505,-0.001903650816530,-0.231333941221237,-0.120703168213367,0.003843819489703,0.089685842394829,0.151363283395767,-0.049702979624271,0.080909289419651) * FEATURE3_texOff(vec2(0,1));
res += mat4(0.043414156883955,0.076740071177483,-0.147333517670631,0.044077776372433,0.033728677779436,-0.116082489490509,-0.163004949688911,0.155877977609634,0.214832484722137,0.057464275509119,-0.313642203807831,-0.057979367673397,-0.153696402907372,0.160789608955383,0.215177044272423,-0.168301612138748) * FEATURE3_texOff(vec2(1,-1));
res += mat4(0.220994129776955,-0.048813659697771,-0.466448098421097,0.333554893732071,-0.005209001712501,0.047743145376444,0.058893468230963,-0.229662805795670,-0.264974057674408,0.258529752492905,0.320057749748230,-0.183986172080040,0.116945855319500,0.116854935884476,-0.218388885259628,0.020135734230280) * FEATURE3_texOff(vec2(1,0));
res += mat4(-0.104750335216522,0.072412766516209,0.149877116084099,-0.082270979881287,0.086463674902916,-0.085894450545311,0.031288180500269,0.088364727795124,-0.077340371906757,0.049953859299421,0.118108883500099,0.038362316787243,-0.390374839305878,0.138845860958099,0.348383307456970,0.040732000023127) * FEATURE3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.497519999742508,0.058784224092960,-0.011795911006629,0.514739453792572) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(-0.520570099353790,-0.004246998112649,-0.093602478504181,0.027081957086921);
res += mat4(-0.077778331935406,0.072147503495216,0.039031252264977,0.132688835263252,0.170524835586548,0.066501602530479,0.030155716463923,-0.052492942661047,-0.261255353689194,0.020513348281384,-0.335453659296036,0.108800277113914,0.042668454349041,0.014437692239881,0.086307525634766,-0.158056005835533) * FEATURE1_texOff(vec2(-1,-1));
res += mat4(-0.138210475444794,-0.264479160308838,0.042473223060369,-0.017764331772923,0.047674719244242,-0.012932275421917,-0.014899857342243,-0.103875659406185,0.458813130855560,0.191955253481865,-0.159509435296059,-0.452704817056656,0.193917229771614,-0.125169828534126,-0.162041440606117,0.126912787556648) * FEATURE1_texOff(vec2(-1,0));
res += mat4(0.071339033544064,0.145096346735954,-0.009100492112339,-0.102989181876183,0.027661992236972,0.031299743801355,-0.095031477510929,-0.084616757929325,-0.281129091978073,-0.252442896366119,0.550774335861206,0.116975836455822,-0.143474951386452,-0.293625473976135,-0.115509472787380,0.158566862344742) * FEATURE1_texOff(vec2(-1,1));
res += mat4(0.094340220093727,0.215451344847679,0.110667273402214,-0.191776022315025,0.062116220593452,0.121529139578342,0.018489770591259,-0.069164887070656,-0.081976041197777,0.094529688358307,-0.081757880747318,-0.008565169759095,0.047904547303915,-0.090409494936466,-0.012907024472952,0.021412996575236) * FEATURE1_texOff(vec2(0,-1));
res += mat4(0.010193317197263,-0.423857837915421,0.318510264158249,0.027779348194599,-0.053365286439657,-0.022336868569255,-0.273601651191711,-0.208125486969948,-0.208783775568008,-0.061647534370422,-0.381679385900497,0.492646634578705,-0.175349801778793,-0.083415299654007,0.193258151412010,0.138598844408989) * FEATURE1_texOff(vec2(0,0));
res += mat4(-0.024889709427953,0.137447580695152,-0.192480400204659,-0.215854123234749,-0.033606134355068,0.212571650743484,0.065257333219051,-0.093213491141796,0.099099248647690,0.253523558378220,-0.037354879081249,-0.318365722894669,-0.258138567209244,-0.357319086790085,-0.025374444201589,-0.188248276710510) * FEATURE1_texOff(vec2(0,1));
res += mat4(-0.255162298679352,-0.068044923245907,-0.343515068292618,-0.136068046092987,0.117284163832664,-0.006763117853552,-0.269961029291153,-0.174896016716957,0.021951103582978,0.048044722527266,0.304274171590805,-0.237208470702171,0.141141846776009,0.022961704060435,0.076141454279423,-0.199895784258842) * FEATURE1_texOff(vec2(1,-1));
res += mat4(-0.089265502989292,0.447687178850174,-0.031696375459433,-0.145254507660866,-0.235507473349571,-0.032915763556957,0.073160514235497,-0.345638334751129,0.078008860349655,-0.089633427560329,0.314374178647995,0.119172357022762,0.197795495390892,-0.183835506439209,-0.277163177728653,-0.154749035835266) * FEATURE1_texOff(vec2(1,0));
res += mat4(0.077549465000629,-0.093517482280731,0.021621592342854,-0.106581911444664,0.014172887429595,0.079842589795589,-0.108546324074268,-0.078602418303490,0.104666270315647,0.085290752351284,-0.246847614645958,0.160703584551811,0.162848517298698,-0.038192581385374,0.200609758496284,-0.131014108657837) * FEATURE1_texOff(vec2(1,1));
res += mat4(0.179649308323860,0.016445467248559,0.132877498865128,0.121298111975193,0.143738582730293,-0.202205911278725,-0.050630379468203,0.110950089991093,0.111592307686806,0.014446264132857,0.128266245126724,0.039984446018934,0.096136756241322,-0.080311015248299,0.015902215614915,-0.148239925503731) * FEATURE2_texOff(vec2(-1,-1));
res += mat4(-0.140294417738914,0.082838915288448,0.043224282562733,0.049853343516588,-0.029283657670021,0.036058072000742,0.285987973213196,-0.030416609719396,0.020127216354012,-0.204568400979042,-0.158963829278946,0.038395781069994,0.025672079995275,0.078326955437660,-0.192696750164032,-0.173772990703583) * FEATURE2_texOff(vec2(-1,0));
res += mat4(-0.151317134499550,0.235480830073357,0.251536011695862,0.049239460378885,0.090834833681583,0.256637990474701,-0.166311740875244,0.015654725953937,0.050301164388657,0.364794075489044,0.048085335642099,-0.357768237590790,0.048536602407694,0.006031821947545,-0.026890000328422,-0.061978869140148) * FEATURE2_texOff(vec2(-1,1));
res += mat4(-0.424423664808273,-0.110199473798275,-0.304749816656113,0.083835244178772,0.133748710155487,-0.089248098433018,-0.187548682093620,0.078266479074955,0.191254928708076,-0.001955869840458,0.013822439126670,-0.096786558628082,-0.085552491247654,-0.136480763554573,0.177042067050934,-0.092528134584427) * FEATURE2_texOff(vec2(0,-1));
res += mat4(0.225004076957703,0.525971353054047,-0.117775149643421,-0.145536378026009,0.320386260747910,-0.013724784366786,-0.012080152519047,0.024151060730219,-0.232210010290146,-0.080515801906586,0.114520899951458,-0.066902257502079,-0.221809923648834,-0.111587218940258,-0.314129352569580,0.163026914000511) * FEATURE2_texOff(vec2(0,0));
res += mat4(0.298849493265152,-0.421943813562393,0.104416728019714,0.062732137739658,-0.054500937461853,-0.209909379482269,0.099804945290089,-0.042509034276009,0.243156626820564,0.420204162597656,-0.044595871120691,-0.441718727350235,0.146326586604118,0.434287220239639,-0.016612133011222,-0.155752971768379) * FEATURE2_texOff(vec2(0,1));
res += mat4(0.191960677504539,-0.049889445304871,-0.011507952585816,-0.092677369713783,-0.058856546878815,0.023898899555206,0.341989934444427,-0.113944418728352,-0.077346920967102,-0.092371247708797,0.000713122484740,-0.062863588333130,-0.081780381500721,0.062755897641182,0.075872510671616,-0.021590221673250) * FEATURE2_texOff(vec2(1,-1));
res += mat4(-0.078373365104198,-0.140493854880333,-0.056391645222902,0.110063269734383,-0.259909838438034,0.034718278795481,-0.323916852474213,0.202735379338264,0.076339825987816,0.028334725648165,0.100102007389069,0.028072239831090,-0.224355027079582,-0.021707750856876,-0.066676937043667,-0.126003503799438) * FEATURE2_texOff(vec2(1,0));
res += mat4(-0.111121952533722,0.051332429051399,-0.053149040788412,-0.030072420835495,-0.141847968101501,0.248987182974815,-0.153213471174240,-0.068546794354916,0.085497468709946,0.114448904991150,-0.250635415315628,-0.195287063717842,0.003699701745063,0.104220658540726,-0.253738760948181,-0.019137280061841) * FEATURE2_texOff(vec2(1,1));
res += mat4(0.102343291044235,0.074087165296078,-0.039245344698429,0.127451971173286,-0.094662740826607,0.059591714292765,-0.041918728500605,-0.154409602284431,-0.152642831206322,-0.009484192356467,0.087486855685711,-0.037502419203520,-0.032219555228949,0.203632012009621,-0.156240731477737,0.146666929125786) * FEATURE3_texOff(vec2(-1,-1));
res += mat4(0.161102041602135,-0.086492836475372,0.010420955717564,0.051900751888752,-0.001965983072296,-0.111830443143845,-0.178617313504219,-0.530517220497131,-0.284775316715240,-0.124909125268459,-0.080975025892258,-0.030536878854036,0.188945934176445,-0.086512364447117,0.287389397621155,0.225668251514435) * FEATURE3_texOff(vec2(-1,0));
res += mat4(0.225303679704666,-0.136075735092163,0.024543318897486,-0.089475147426128,0.135772421956062,-0.031742282211781,-0.017272286117077,-0.355950176715851,-0.020268565043807,0.445551961660385,-0.098369479179382,0.218400567770004,-0.007921676151454,-0.135622456669807,-0.150115311145782,0.063444375991821) * FEATURE3_texOff(vec2(-1,1));
res += mat4(0.257108122110367,-0.130416139960289,0.310548633337021,-0.004453357774764,0.120140329003334,-0.013954373076558,0.013360658660531,0.107527241110802,-0.274376779794693,-0.120714463293552,0.067517362535000,-0.079974383115768,-0.139048993587494,0.238967806100845,-0.407415390014648,0.730281233787537) * FEATURE3_texOff(vec2(0,-1));
res += mat4(-0.809303939342499,0.069256670773029,-0.010072197765112,0.088632017374039,0.141108497977257,0.049920521676540,0.176429733633995,0.143704384565353,-0.322184175252914,-0.010807177051902,-0.130053192377090,-0.040977694094181,0.613645434379578,0.164730936288834,0.078906878829002,-0.714655876159668) * FEATURE3_texOff(vec2(0,0));
res += mat4(-0.075197577476501,0.091883867979050,0.023224331438541,-0.147692918777466,0.163263812661171,0.240646004676819,-0.177344679832458,0.072526656091213,0.146646901965141,0.464719951152802,-0.023065738379955,-0.203694581985474,-0.165114641189575,-0.698597609996796,0.379068046808243,0.137945994734764) * FEATURE3_texOff(vec2(0,1));
res += mat4(0.110460519790649,-0.051306325942278,-0.328619718551636,0.002934977179393,-0.068959303200245,-0.189236775040627,-0.202078416943550,0.050078555941582,-0.028978023678064,-0.155674457550049,0.129920169711113,-0.090692356228828,-0.076568126678467,0.016800206154585,0.449018985033035,-0.047672104090452) * FEATURE3_texOff(vec2(1,-1));
res += mat4(-0.373307764530182,0.024651564657688,0.311163097620010,-0.064961582422256,0.130250439047813,0.088637702167034,0.369190126657486,0.088538408279419,0.113344021141529,0.070495441555977,0.160668388009071,-0.089403390884399,-0.411611706018448,0.125160872936249,-0.484194368124008,0.091849304735661) * FEATURE3_texOff(vec2(1,0));
res += mat4(0.117131479084492,0.093214191496372,-0.107737794518471,-0.217244893312454,0.019019925966859,0.052566990256310,0.337479501962662,0.203063443303108,-0.176093608140945,-0.018700016662478,-0.196833565831184,0.126525342464447,0.001728071714751,0.198958501219749,0.001557390205562,-0.002886726288125) * FEATURE3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.052897043526173,-0.013200596906245,-0.449018537998199,0.934653997421265) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND FEATURE1
//!BIND FEATURE2
//!BIND FEATURE3
//!SAVE MODEL2
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 1_2

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.116233013570309,-0.375317335128784,0.031150845810771,0.014600822702050);
res += mat4(-0.076788924634457,-0.169890403747559,-0.024420440196991,0.016176329925656,-0.046181023120880,0.002681501908228,0.218292906880379,-0.052994582802057,0.017816163599491,-0.006572695914656,-0.105200856924057,-0.013052949681878,-0.041251458227634,0.106202088296413,0.150216504931450,0.124145306646824) * FEATURE1_texOff(vec2(-1,-1));
res += mat4(-0.025483133271337,0.028051704168320,-0.366708666086197,-0.078737236559391,-0.321899950504303,-0.148270830512047,0.113570928573608,0.129918366670609,-0.061731137335300,0.277807742357254,0.034648515284061,0.138488501310349,-0.231128960847855,-0.059376303106546,-0.299756228923798,-0.118029534816742) * FEATURE1_texOff(vec2(-1,0));
res += mat4(-0.222253769636154,-0.006410469766706,0.157835364341736,0.041552569717169,-0.162291377782822,0.113414041697979,0.290863215923309,-0.050167690962553,-0.023423800244927,0.002460780320689,0.183294162154198,0.007199306041002,-0.006017484236509,-0.183856621384621,-0.124432101845741,-0.018017699941993) * FEATURE1_texOff(vec2(-1,1));
res += mat4(-0.066261991858482,-0.064730912446976,-0.105725675821304,0.074338607490063,-0.193939507007599,-0.122237734496593,-0.070180699229240,0.049821678549051,-0.001136585487984,0.208774089813232,0.204097732901573,-0.003573761321604,0.007572621107101,-0.148487046360970,0.044385381042957,-0.015394979156554) * FEATURE1_texOff(vec2(0,-1));
res += mat4(-0.405568897724152,-0.193879336118698,-0.373974353075027,0.030976254492998,-0.366117686033249,-0.288991510868073,-0.062945313751698,0.002973403548822,-0.060525931417942,0.357122033834457,0.348207771778107,0.166719198226929,-0.384759008884430,-0.056253403425217,0.099473111331463,0.060258891433477) * FEATURE1_texOff(vec2(0,0));
res += mat4(0.134780362248421,0.322454243898392,0.270093917846680,0.084926590323448,0.205518111586571,0.192903727293015,0.213361814618111,0.301619738340378,-0.075581192970276,-0.333190262317657,-0.183986410498619,-0.400001496076584,-0.054656721651554,-0.251885354518890,0.008008813485503,0.098949044942856) * FEATURE1_texOff(vec2(0,1));
res += mat4(0.203635141253471,0.182137936353683,0.054592572152615,-0.011093143373728,0.274002492427826,-0.062102332711220,0.205423116683960,0.061306569725275,0.086820460855961,0.171413615345955,0.029225474223495,0.108331009745598,0.063814908266068,0.005241898354143,-0.205291584134102,0.367664545774460) * FEATURE1_texOff(vec2(1,-1));
res += mat4(0.027198877185583,-0.165085107088089,0.079894483089447,-0.071696385741234,0.433056443929672,0.123250231146812,-0.053923495113850,-0.010329023003578,-0.059268817305565,0.042527284473181,-0.334009975194931,0.200443625450134,0.829617321491241,0.020968342199922,0.353321790695190,-0.084374189376831) * FEATURE1_texOff(vec2(1,0));
res += mat4(-0.138305380940437,-0.063636869192123,0.022352728992701,-0.006011545658112,-0.096739381551743,-0.062763668596745,-0.039967738091946,0.034276671707630,0.137503102421761,-0.029714627191424,0.089740619063377,-0.185770884156227,-0.130397617816925,0.128423050045967,-0.184017866849899,0.030781239271164) * FEATURE1_texOff(vec2(1,1));
res += mat4(0.037854019552469,0.103734113276005,-0.092883199453354,-0.025098308920860,0.055547095835209,0.103953242301941,-0.070719532668591,0.056342218071222,-0.001892852596939,-0.284497678279877,-0.060635760426521,0.029167309403419,-0.075349301099777,-0.212764889001846,-0.229442715644836,-0.028174804523587) * FEATURE2_texOff(vec2(-1,-1));
res += mat4(-0.031264055520296,0.111735559999943,-0.200082510709763,-0.287819176912308,0.035691961646080,0.106386616826057,0.103795260190964,0.123985722661018,0.013475642539561,0.176504060626030,-0.307512044906616,-0.180631622672081,0.062993288040161,-0.175519242882729,0.188007876276970,-0.306443572044373) * FEATURE2_texOff(vec2(-1,0));
res += mat4(-0.000420851894887,-0.073122516274452,0.465369731187820,-0.508160352706909,-0.009128943085670,0.014177996665239,-0.180158138275146,-0.124940805137157,0.092440210282803,-0.001233046059497,-0.004397174809128,-0.076183624565601,0.031485758721828,0.063059702515602,0.217897713184357,0.095267347991467) * FEATURE2_texOff(vec2(-1,1));
res += mat4(0.004766330122948,0.148044303059578,0.068482488393784,0.065873622894287,0.121471673250198,0.094063110649586,-0.190166562795639,-0.071942299604416,0.050590716302395,-0.321750372648239,0.139370188117027,0.094845920801163,-0.054965525865555,-0.187017470598221,-0.131809219717979,-0.082346946001053) * FEATURE2_texOff(vec2(0,-1));
res += mat4(0.126341298222542,0.070612251758575,-0.151929810643196,0.130181163549423,-0.056750115007162,-0.089068204164505,0.479348599910736,0.038684807717800,0.109670959413052,0.201227858662605,0.153581246733665,-0.113365784287453,0.347020387649536,0.462103992700577,0.195727556943893,0.249120265245438) * FEATURE2_texOff(vec2(0,0));
res += mat4(0.230217456817627,-0.385497719049454,-0.011988110840321,-0.486701428890228,0.032095078378916,-0.119974836707115,0.189609572291374,0.192466437816620,-0.391934216022491,0.672750532627106,0.427033096551895,0.467029005289078,-0.205531358718872,-0.041915170848370,-0.317905426025391,-0.165837585926056) * FEATURE2_texOff(vec2(0,1));
res += mat4(0.060099530965090,0.035346832126379,-0.024481110274792,0.072140604257584,-0.047961693257093,-0.126105219125748,-0.056793648749590,0.148212537169456,-0.060810633003712,-0.329486250877380,-0.169233366847038,-0.003358658170328,0.167275294661522,0.267912209033966,0.103311829268932,0.083789288997650) * FEATURE2_texOff(vec2(1,-1));
res += mat4(-0.037051346153021,-0.009296830743551,-0.052827119827271,-0.083917260169983,0.552954673767090,0.209101200103760,0.291184186935425,-0.275674939155579,0.392218470573425,-0.118901237845421,0.172087758779526,-0.128298163414001,-0.258655756711960,-0.257012039422989,-0.230582922697067,0.318375438451767) * FEATURE2_texOff(vec2(1,0));
res += mat4(0.092993892729282,0.054747313261032,-0.219761937856674,0.017567584291101,-0.008170821703970,-0.028794573619962,-0.122894138097763,0.077548123896122,0.132583364844322,-0.187707185745239,-0.423731088638306,0.226792827248573,-0.033568877726793,-0.160651564598083,-0.104655250906944,-0.316843062639236) * FEATURE2_texOff(vec2(1,1));
res += mat4(0.030629310756922,0.154071554541588,-0.168351694941521,0.031322315335274,-0.012637122534215,0.100530073046684,0.267188549041748,0.024032633751631,-0.056034050881863,-0.050520148128271,-0.154243662953377,-0.162540197372437,0.033296521753073,-0.054307851940393,-0.162556692957878,-0.009338302537799) * FEATURE3_texOff(vec2(-1,-1));
res += mat4(-0.010970163159072,0.072897091507912,0.208181276917458,0.032789256423712,-0.110182993113995,0.152846783399582,-0.137564778327942,0.050801161676645,0.020742965862155,0.012628843076527,-0.143606036901474,-0.062881879508495,0.105604998767376,0.099327638745308,-0.007519947364926,-0.104492574930191) * FEATURE3_texOff(vec2(-1,0));
res += mat4(-0.072841361165047,-0.013717111200094,0.031640276312828,-0.052549887448549,-0.074808448553085,0.115598626434803,0.093100525438786,-0.146555751562119,0.058638706803322,0.090838521718979,0.168992355465889,0.022502599284053,-0.042407836765051,0.123613715171814,-0.043555155396461,-0.037387672811747) * FEATURE3_texOff(vec2(-1,1));
res += mat4(0.119206383824348,0.106454670429230,-0.065706834197044,0.230743050575256,-0.153052777051926,0.059250988066196,0.059321854263544,-0.056363645941019,-0.034577175974846,0.067528218030930,-0.048725817352533,0.194860517978668,-0.161583542823792,-0.100325651466846,-0.098773889243603,0.138789400458336) * FEATURE3_texOff(vec2(0,-1));
res += mat4(-0.231323257088661,0.228516146540642,-0.043665520846844,0.005266212392598,-0.283726900815964,0.057166635990143,-0.067329987883568,-0.043925989419222,0.164679825305939,0.129683420062065,0.026255669072270,-0.008457593619823,-0.056929904967546,-0.311973899602890,-0.039656743407249,-0.485970944166183) * FEATURE3_texOff(vec2(0,0));
res += mat4(0.119731284677982,0.072058968245983,-0.021896084770560,-0.268797844648361,0.017664428800344,0.058973159641027,0.083062253892422,0.239217624068260,0.022083017975092,-0.209837377071381,0.193939164280891,0.038525588810444,0.110856696963310,0.211870163679123,0.441038966178894,0.322472840547562) * FEATURE3_texOff(vec2(0,1));
res += mat4(-0.284807473421097,-0.471298038959503,0.072528973221779,0.016381541267037,-0.027138501405716,-0.145620509982109,-0.061630532145500,-0.169918477535248,0.133674696087837,-0.101018011569977,0.058823909610510,-0.043472126126289,-0.022111074998975,0.097012795507908,-0.155075296759605,0.098713032901287) * FEATURE3_texOff(vec2(1,-1));
res += mat4(-0.444262146949768,-0.536844789981842,-0.262577801942825,0.119689747691154,0.293151348829269,-0.058371409773827,0.051238559186459,-0.240157559514046,0.012266146019101,0.345338165760040,0.095602072775364,0.122302249073982,0.215026795864105,-0.100975453853607,-0.141509279608727,-0.192767396569252) * FEATURE3_texOff(vec2(1,0));
res += mat4(-0.032301854342222,0.008792613632977,-0.139276683330536,-0.083255589008331,0.008659945800900,0.076864913105965,0.012264686636627,-0.052656218409538,-0.046535208821297,-0.060641303658485,0.076550468802452,-0.041266310960054,-0.146784618496895,0.052523020654917,0.130808025598526,0.249507859349251) * FEATURE3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.155703216791153,0.047926258295774,0.754693806171417,0.187885448336601) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(-0.003600387368351,0.025340178981423,0.169998064637184,-0.103534519672394);
res += mat4(0.009102466516197,-0.147147521376610,-0.025596799328923,-0.097892776131630,-0.107598893344402,0.046669300645590,0.196421056985855,0.212881371378899,-0.191614314913750,-0.224296227097511,0.131013676524162,-0.219802960753441,-0.155367106199265,-0.075816981494427,-0.165235221385956,0.140437111258507) * FEATURE1_texOff(vec2(-1,-1));
res += mat4(-0.081293128430843,0.034086327999830,0.081669166684151,-0.071506306529045,0.001695694867522,0.214002624154091,0.068742103874683,-0.194424271583557,-0.014250860549510,-0.154902786016464,-0.316240698099136,0.289604932069778,-0.010041525587440,0.180181145668030,-0.171435400843620,-0.889737069606781) * FEATURE1_texOff(vec2(-1,0));
res += mat4(-0.065326787531376,-0.051954109221697,0.021000389009714,0.060555614531040,0.015106839127839,0.185948148369789,0.033741120249033,0.010429659858346,-0.126663088798523,0.259517639875412,0.222812443971634,-0.171884790062904,-0.519635260105133,0.042038738727570,-0.497792840003967,-0.189691215753555) * FEATURE1_texOff(vec2(-1,1));
res += mat4(-0.530564427375793,-0.493166863918304,0.018420875072479,0.055667828768492,-0.092044092714787,0.011134020984173,-0.049389969557524,0.317675173282623,0.098046213388443,0.130854889750481,-0.223617956042290,-0.033210180699825,0.031551264226437,0.146439671516418,-0.002596506150439,-0.139617636799812) * FEATURE1_texOff(vec2(0,-1));
res += mat4(-0.010097329504788,0.000341608538292,-0.084866471588612,-0.160298332571983,0.303094625473022,-0.151712745428085,0.140444621443748,-0.082434594631195,0.553794264793396,0.047976650297642,0.354670614004135,-0.039199635386467,-0.045647028833628,-0.088023729622364,-0.479999542236328,0.977888107299805) * FEATURE1_texOff(vec2(0,0));
res += mat4(-0.008060921914876,0.117358878254890,-0.193733811378479,0.068597681820393,0.159006968140602,-0.119265377521515,-0.154286384582520,-0.088756315410137,-0.162838935852051,-0.013074455782771,-0.149512529373169,0.133441179990768,0.274233460426331,0.188986942172050,0.266630858182907,-0.000554185418878) * FEATURE1_texOff(vec2(0,1));
res += mat4(0.371598899364471,0.171195119619370,0.831240773200989,-0.529089093208313,0.014134931378067,0.104688495397568,0.175172984600067,-0.474857032299042,-0.003623085329309,-0.036842465400696,-0.030115814879537,-0.124520793557167,0.026755159720778,-0.034461613744497,0.083156116306782,-0.071059599518776) * FEATURE1_texOff(vec2(1,-1));
res += mat4(0.036949317902327,-0.060451038181782,-0.003763854270801,0.081137686967850,-0.317048519849777,-0.248259425163269,0.095852553844452,-0.337969869375229,0.137501418590546,-0.135801777243614,0.038680657744408,-0.101474061608315,0.080335050821304,-0.141440704464912,-0.276297390460968,0.104676350951195) * FEATURE1_texOff(vec2(1,0));
res += mat4(0.140206351876259,0.025324726477265,0.003900266950950,-0.068804152309895,-0.487791955471039,0.014714037999511,-0.158892408013344,-0.012809971347451,-0.196461394429207,0.079219780862331,0.010690622963011,0.036620303988457,0.159060001373291,-0.217912867665291,0.009962084703147,-0.048125360161066) * FEATURE1_texOff(vec2(1,1));
res += mat4(0.238060891628265,0.061669051647186,-0.092881627380848,0.088260374963284,-0.106778018176556,-0.044647052884102,0.021739725023508,0.259980559349060,-0.066723637282848,0.200315549969673,0.010343682952225,0.060990862548351,-0.205018490552902,0.019935870543122,0.060503408312798,-0.167431205511093) * FEATURE2_texOff(vec2(-1,-1));
res += mat4(-0.023423703387380,0.247724875807762,-0.136184602975845,0.023487102240324,0.231168374419212,-0.024729972705245,0.175514191389084,-0.216386437416077,-0.118947342038155,-0.221288606524467,0.049035463482141,-0.314657449722290,-0.235422164201736,-0.402548462152481,-0.023747807368636,0.043596368283033) * FEATURE2_texOff(vec2(-1,0));
res += mat4(-0.144865036010742,0.023564897477627,0.211332842707634,0.017456231638789,0.341216146945953,0.188891261816025,-0.192747175693512,-0.127174451947212,-0.251506090164185,0.074694395065308,-0.152729690074921,-0.060621514916420,-0.030324412509799,0.127752065658569,-0.102188840508461,0.071019649505615) * FEATURE2_texOff(vec2(-1,1));
res += mat4(0.051675386726856,-0.110768288373947,-0.026421323418617,-0.149118915200233,0.050748161971569,-0.092640548944473,0.236698478460312,-0.258085638284683,0.036704819649458,-0.102409519255161,-0.151673659682274,-0.012596287764609,0.132772564888000,-0.319601118564606,0.032175388187170,0.518112719058990) * FEATURE2_texOff(vec2(0,-1));
res += mat4(-0.012912257574499,-0.294367045164108,-0.012851522304118,-0.104858674108982,-0.476630687713623,-0.471014946699142,-0.229010611772537,-0.120173744857311,0.216441839933395,-0.018385613337159,0.296150624752045,0.102862842381001,0.418590039014816,-0.285847216844559,0.101269274950027,-0.362018436193466) * FEATURE2_texOff(vec2(0,0));
res += mat4(-0.236876562237740,-0.142679274082184,-0.018312714993954,-0.004562242887914,-0.191304281353951,0.036123324185610,-0.065918453037739,0.114265859127045,0.133311718702316,0.166300833225250,-0.219079017639160,0.128476396203041,0.170779943466187,-0.120958305895329,-0.198557659983635,-0.049502097070217) * FEATURE2_texOff(vec2(0,1));
res += mat4(-0.250796675682068,-0.033411838114262,0.020944390445948,0.045177169144154,0.018793312832713,0.075261339545250,0.078848108649254,0.191208183765411,0.160893991589546,0.037083890289068,0.166766390204430,-0.030853070318699,0.095482140779495,0.072703324258327,0.301883906126022,0.641828238964081) * FEATURE2_texOff(vec2(1,-1));
res += mat4(0.149183928966522,0.015829097479582,-0.044544961303473,0.024019485339522,0.123764835298061,0.097484447062016,0.029235458001494,0.046647205948830,-0.188275337219238,-0.014631928876042,0.082194335758686,-0.160660490393639,0.105569586157799,0.317157030105591,-0.067013330757618,-0.229150027036667) * FEATURE2_texOff(vec2(1,0));
res += mat4(0.349734544754028,0.147827833890915,-0.086244478821754,0.102486386895180,0.042420439422131,0.050860427320004,-0.098152138292789,0.043869692832232,0.007115731947124,0.044890508055687,-0.018837358802557,0.060868464410305,-0.005251543130726,-0.028602642938495,-0.013501704670489,0.007992091588676) * FEATURE2_texOff(vec2(1,1));
res += mat4(0.034416764974594,0.105616696178913,-0.293383032083511,-0.172671750187874,-0.225567519664764,-0.235076621174812,0.106663115322590,-0.161997884511948,0.406902730464935,-0.291569799184799,0.076741546392441,0.452571034431458,0.228716686367989,0.295781463384628,0.229774832725525,0.032574452459812) * FEATURE3_texOff(vec2(-1,-1));
res += mat4(0.048502523452044,-0.370624929666519,-0.076125048100948,-0.107259184122086,-0.339508384466171,-0.170677930116653,-0.005857000127435,0.062369219958782,0.538038194179535,0.003736931597814,-0.084627315402031,-0.020844062790275,-0.233678042888641,0.519837021827698,-0.301151126623154,-0.088258132338524) * FEATURE3_texOff(vec2(-1,0));
res += mat4(-0.298833012580872,-0.071250118315220,0.050397571176291,0.022675415500998,-0.119043588638306,-0.197844251990318,-0.154100909829140,0.127146884799004,0.267561674118042,0.151433363556862,0.035205278545618,-0.040184184908867,-0.126212969422340,-0.440704971551895,-0.010754436254501,0.079519405961037) * FEATURE3_texOff(vec2(-1,1));
res += mat4(0.042930170893669,0.275731444358826,-0.420036792755127,0.571346282958984,-0.071195378899574,-0.010161907412112,0.274973660707474,0.040308848023415,0.278248339891434,-0.088136889040470,0.160750806331635,0.419665545225143,-0.066834114491940,-0.075773715972900,0.216640621423721,-0.695190846920013) * FEATURE3_texOff(vec2(0,-1));
res += mat4(0.044876474887133,-0.297728449106216,0.321529269218445,-0.130395248532295,0.041998043656349,0.506950914859772,-0.010072753764689,-0.013775953091681,0.322274386882782,0.157335385680199,0.160569995641708,-0.122522816061974,-0.114358484745026,-0.855323553085327,-0.162538677453995,0.130311310291290) * FEATURE3_texOff(vec2(0,0));
res += mat4(-0.132264956831932,0.160095408558846,0.150279968976974,0.004173722118139,-0.083219610154629,-0.053457677364349,-0.138078212738037,0.001178017701022,0.023413350805640,0.087089106440544,0.004321262240410,0.089092649519444,0.038372568786144,0.132294654846191,0.131122037768364,-0.028245689347386) * FEATURE3_texOff(vec2(0,1));
res += mat4(0.069247685372829,-0.118321098387241,-0.077156580984592,0.190836891531944,0.057616725564003,0.004161442629993,0.174798220396042,-0.220942586660385,-0.052527349442244,-0.006137512624264,-0.090660199522972,-0.096689313650131,-0.065271615982056,0.005570048000664,-0.096096396446228,0.270545065402985) * FEATURE3_texOff(vec2(1,-1));
res += mat4(0.005192223936319,0.404008418321609,0.138291969895363,0.032534148544073,0.148785308003426,-0.065805986523628,-0.144455000758171,0.137953326106071,0.075690321624279,0.221712812781334,-0.021980727091432,0.105197705328465,0.317297071218491,0.214379370212555,-0.015364015474916,0.095894753932953) * FEATURE3_texOff(vec2(1,0));
res += mat4(0.119459815323353,-0.165160343050957,-0.058053214102983,-0.079390339553356,0.340984195470810,0.100856207311153,0.076476544141769,0.201001942157745,-0.052247673273087,-0.063743747770786,0.004557212349027,-0.134526327252388,-0.200814455747604,-0.034801058471203,0.020906632766128,0.010477757081389) * FEATURE3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.238149985671043,-0.052779238671064,-0.222673892974854,-0.088702984154224) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND FEATURE1
//!BIND FEATURE2
//!BIND FEATURE3
//!SAVE MODEL3
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 1_3

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.163783043622971,-0.101848706603050,-0.104125238955021,-0.111403279006481);
res += mat4(0.273251026868820,0.070758901536465,0.159742802381516,0.169537082314491,0.180958524346352,0.062667839229107,-0.019714051857591,0.019397621974349,0.018079869449139,0.050627551972866,0.036335673183203,0.131875351071358,-0.134130984544754,0.116782613098621,0.147269278764725,-0.189815029501915) * FEATURE1_texOff(vec2(-1,-1));
res += mat4(-0.361015707254410,0.387154817581177,-0.073395103216171,-0.230710610747337,-0.273744940757751,-0.228782132267952,0.186787992715836,0.255630314350128,0.019455909729004,0.180428862571716,-0.013189267367125,-0.102228134870529,0.032212838530540,-0.102220997214317,0.032106727361679,0.368544936180115) * FEATURE1_texOff(vec2(-1,0));
res += mat4(-0.032808035612106,-0.141789466142654,0.213314250111580,0.030834740027785,-0.085966415703297,-0.217638805508614,-0.078001201152802,-0.236755818128586,-0.049992173910141,-0.114556089043617,0.011140206828713,0.000038489506551,-0.017901860177517,0.044603642076254,-0.086222603917122,0.170638993382454) * FEATURE1_texOff(vec2(-1,1));
res += mat4(0.192850589752197,-0.189444765448570,0.007228216622025,0.125734582543373,0.094254568219185,0.122275844216347,0.138314127922058,0.122292026877403,0.046412844210863,-0.102075077593327,-0.172658309340477,0.005476214922965,0.205351307988167,0.254133254289627,-0.297754436731339,-0.289752453565598) * FEATURE1_texOff(vec2(0,-1));
res += mat4(0.019212203100324,-0.276436030864716,-0.188408792018890,0.317281126976013,-0.027212427929044,-0.316759347915649,0.516443967819214,0.452270209789276,-0.240648597478867,0.325802445411682,-0.215641081333160,-0.374385237693787,-0.029962228611112,-0.245208024978638,0.175951033830643,0.843245387077332) * FEATURE1_texOff(vec2(0,0));
res += mat4(-0.522483766078949,0.016384569928050,-0.012295236811042,-0.266639083623886,-0.521738827228546,-0.404546469449997,-0.459754019975662,-0.660132765769958,-0.001449272735044,-0.105413787066936,-0.134428799152374,0.024740513414145,-0.058979928493500,-0.006160106975585,-0.308213919401169,0.074513792991638) * FEATURE1_texOff(vec2(0,1));
res += mat4(-0.056004632264376,0.010828392580152,0.025822130963206,0.080242663621902,-0.030328491702676,-0.070918507874012,0.022544259205461,-0.228092014789581,-0.033995103091002,0.086836881935596,0.121107392013073,-0.169401571154594,-0.226599991321564,0.000384184764698,0.062431301921606,-0.373251885175705) * FEATURE1_texOff(vec2(1,-1));
res += mat4(0.005879424512386,0.134728685021400,0.068072795867920,-0.053059499710798,-0.198077395558357,-0.126363590359688,-0.106702946126461,-0.415023624897003,0.239687442779541,0.055773653090000,-0.116156093776226,0.016970371827483,-0.125967383384705,0.072432272136211,0.046166773885489,-0.702004194259644) * FEATURE1_texOff(vec2(1,0));
res += mat4(0.052426189184189,-0.070467658340931,0.327032059431076,0.135220363736153,-0.274068087339401,-0.219640091061592,0.053507987409830,-0.153573557734489,-0.162769481539726,0.023839289322495,0.213881015777588,-0.046278357505798,-0.060678467154503,-0.162132814526558,0.107284344732761,-0.341579049825668) * FEATURE1_texOff(vec2(1,1));
res += mat4(0.102629654109478,0.051589984446764,-0.116968683898449,-0.134407907724380,-0.085065640509129,-0.059872977435589,0.159564897418022,-0.061324179172516,-0.089459098875523,-0.050842776894569,0.264938861131668,0.010017615742981,0.002895422047004,0.166921615600586,-0.173376634716988,0.029830168932676) * FEATURE2_texOff(vec2(-1,-1));
res += mat4(0.133411571383476,0.268170505762100,0.029673038050532,0.007450756151229,0.083897128701210,0.110679954290390,0.253455251455307,0.028492331504822,-0.064282171428204,0.175008684396744,-0.112997427582741,-0.061637740582228,-0.095374569296837,-0.542447984218597,0.096345894038677,0.202302321791649) * FEATURE2_texOff(vec2(-1,0));
res += mat4(0.124352119863033,0.025740928947926,0.652091681957245,0.465460985898972,0.026506168767810,0.160967558622360,-0.072028040885925,-0.070030249655247,0.235748454928398,-0.030805295333266,0.202417388558388,-0.127297192811966,0.185627967119217,-0.131218656897545,-0.087746568024158,0.068609893321991) * FEATURE2_texOff(vec2(-1,1));
res += mat4(-0.082533374428749,0.093904353678226,0.254931390285492,0.038928918540478,-0.302090585231781,-0.108778797090054,0.018351357430220,0.013901753351092,-0.284316986799240,-0.223209887742996,-0.038240749388933,0.105074584484100,0.298824757337570,-0.409439384937286,0.105231359601021,0.234827414155006) * FEATURE2_texOff(vec2(0,-1));
res += mat4(-0.186111211776733,0.072634026408195,0.102638043463230,-0.170709669589996,0.169324874877930,-0.136467427015305,0.066959068179131,-0.339702934026718,-0.030851829797029,-0.136210635304451,-0.334302395582199,-0.027593720704317,-0.274374037981033,0.751235067844391,0.194051235914230,-0.579614758491516) * FEATURE2_texOff(vec2(0,0));
res += mat4(0.221859887242317,-0.091268934309483,-0.383313685655594,0.051590323448181,0.133716955780983,-0.138234689831734,-0.020987931638956,-0.073559328913689,-0.334454983472824,-0.215433746576309,-0.195320025086403,-0.209789976477623,-0.008889713324606,0.113655112683773,-0.126271054148674,-0.030994849279523) * FEATURE2_texOff(vec2(0,1));
res += mat4(-0.045504562556744,0.151693284511566,0.174163177609444,-0.040090292692184,-0.239596009254456,-0.016735559329391,-0.063278593122959,0.191531494259834,0.005800862796605,-0.082027338445187,0.094968251883984,0.037975586950779,0.194775402545929,-0.003070252714679,0.023740286007524,-0.014225671999156) * FEATURE2_texOff(vec2(1,-1));
res += mat4(-0.005125489085913,-0.015766661614180,0.012497186660767,0.036149244755507,-0.431414902210236,0.159641146659851,-0.007751655764878,0.102282956242561,0.178750261664391,0.003425764152780,-0.156906113028526,0.310169517993927,0.187122195959091,0.108303166925907,0.134656116366386,0.166684120893478) * FEATURE2_texOff(vec2(1,0));
res += mat4(0.061555735766888,0.034653864800930,0.327089160680771,-0.045091558247805,-0.114195220172405,-0.237496897578239,-0.012480605393648,0.189092978835106,0.223965704441071,0.009374745190144,0.112584896385670,0.159176275134087,-0.237289607524872,0.000021096075216,-0.251921892166138,-0.001563564874232) * FEATURE2_texOff(vec2(1,1));
res += mat4(-0.040297485888004,0.037351347506046,0.010039808228612,-0.009896757081151,0.042127758264542,-0.091034777462482,-0.215335726737976,-0.278688669204712,0.012092700228095,0.028805511072278,0.031181577593088,-0.064291544258595,0.085168577730656,0.163428559899330,-0.006192723754793,0.028721794486046) * FEATURE3_texOff(vec2(-1,-1));
res += mat4(-0.122059591114521,0.097801037132740,-0.175351634621620,-0.249875724315643,0.030360471457243,0.222712561488152,0.065978534519672,0.187991753220558,-0.121802315115929,-0.139986425638199,-0.232326954603195,0.015236686915159,0.040090613067150,0.074973367154598,-0.044072136282921,-0.034314971417189) * FEATURE3_texOff(vec2(-1,0));
res += mat4(0.080947771668434,-0.043225437402725,-0.040137305855751,0.029332078993320,0.185844659805298,-0.088055446743965,-0.033002082258463,-0.051958225667477,-0.113290295004845,-0.067593313753605,-0.039926759898663,-0.209990382194519,-0.020196698606014,-0.067130997776985,-0.000576904858463,-0.093046583235264) * FEATURE3_texOff(vec2(-1,1));
res += mat4(-0.001997509738430,-0.072533018887043,-0.064846009016037,0.013584353029728,0.181618541479111,0.142221659421921,-0.222108006477356,-0.118984572589397,0.274359047412872,-0.087886184453964,-0.126008629798889,0.124478690326214,-0.335153877735138,0.021327128633857,0.177408680319786,-0.155774205923080) * FEATURE3_texOff(vec2(0,-1));
res += mat4(0.023268897086382,0.266585379838943,-0.492893338203430,-0.315266609191895,0.186173364520073,0.032071750611067,0.402706712484360,0.555419683456421,0.039240282028913,0.213734596967697,0.232357159256935,-0.162860497832298,-0.069268308579922,-0.099673084914684,-0.122208647429943,0.130688533186913) * FEATURE3_texOff(vec2(0,0));
res += mat4(0.111984528601170,0.010975514538586,0.089363373816013,-0.184104993939400,-0.001199558726512,-0.035682551562786,-0.103339314460754,-0.098485991358757,0.150985062122345,-0.056189049035311,-0.096123963594437,0.127775326371193,-0.144565492868423,-0.085799887776375,-0.114786170423031,-0.195317670702934) * FEATURE3_texOff(vec2(0,1));
res += mat4(0.263170003890991,-0.203223273158073,-0.095784150063992,0.288394957780838,0.125191196799278,0.081896416842937,-0.138721004128456,0.106515377759933,0.067294232547283,-0.177972942590714,0.045922957360744,0.163798555731773,-0.079004630446434,0.125157058238983,0.064297474920750,-0.065863020718098) * FEATURE3_texOff(vec2(1,-1));
res += mat4(-0.050477936863899,-0.628006875514984,-0.109796091914177,0.454029470682144,0.013123067095876,-0.055506251752377,0.045117124915123,-0.012119375169277,-0.209438577294350,0.321615010499954,0.180210158228874,-0.178038120269775,-0.002825712552294,-0.073848322033882,-0.150215223431587,0.135559320449829) * FEATURE3_texOff(vec2(1,0));
res += mat4(0.058926958590746,0.048745390027761,0.163540259003639,0.070622704923153,0.126311793923378,0.051414884626865,-0.002008674899116,0.174634620547295,0.054677266627550,-0.087411098182201,0.028043186292052,-0.061532486230135,0.164848774671555,-0.189707472920418,-0.058707825839520,-0.055040899664164) * FEATURE3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.485200256109238,0.820108473300934,0.335061341524124,-0.031724043190479) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.073859140276909,-0.096450775861740,0.059292584657669,-0.040495883673429);
res += mat4(-0.007962587289512,0.152704760432243,0.035870164632797,0.018520841374993,0.075076684355736,-0.036783803254366,0.045914981514215,-0.074582040309906,0.016301777213812,0.075410544872284,0.286429703235626,0.092636764049530,-0.097526848316193,0.079492405056953,-0.057607047259808,-0.069002047181129) * FEATURE1_texOff(vec2(-1,-1));
res += mat4(0.009211429394782,-0.000228088232689,-0.042567316442728,-0.047555219382048,0.099820524454117,0.226674363017082,0.188120499253273,-0.079872250556946,-0.156373485922813,0.032099269330502,-0.292539417743683,-0.448070645332336,0.302487105131149,-0.055962868034840,0.067241080105305,-0.018615428358316) * FEATURE1_texOff(vec2(-1,0));
res += mat4(0.045513361692429,0.053013272583485,0.002818670356646,-0.084826461970806,-0.169637084007263,0.019215559586883,0.441716164350510,-0.031690035015345,-0.025401860475540,-0.016506241634488,-0.075061336159706,0.155176490545273,0.065418444573879,-0.354918539524078,-0.179523468017578,-0.241705343127251) * FEATURE1_texOff(vec2(-1,1));
res += mat4(0.272074520587921,-0.347454220056534,-0.383368432521820,-0.071069903671741,-0.204800546169281,0.164907723665237,-0.187835633754730,-0.050269778817892,-0.151221677660942,-0.086399033665657,-0.023410648107529,0.103130392730236,0.103313490748405,-0.027537493035197,-0.120042212307453,-0.070938788354397) * FEATURE1_texOff(vec2(0,-1));
res += mat4(-0.003466917667538,-0.049469374120235,-0.304975539445877,0.180990189313889,-0.047728449106216,0.002376999007538,0.200883239507675,-0.433463871479034,0.013368189334869,0.555492579936981,0.331170648336411,0.323813438415527,-0.085504926741123,-0.164903372526169,-0.441655009984970,0.040604732930660) * FEATURE1_texOff(vec2(0,0));
res += mat4(0.066325247287750,0.006655208766460,0.100547425448895,0.034188184887171,-0.112961836159229,0.124625794589520,-0.017993990331888,-0.275079458951950,0.421147257089615,0.121771238744259,0.080412924289703,-0.278782486915588,-0.396713644266129,-0.322654306888580,0.378164708614349,0.189501956105232) * FEATURE1_texOff(vec2(0,1));
res += mat4(0.369823813438416,0.098964117467403,0.810690462589264,-0.090193942189217,0.012087438255548,0.171426102519035,-0.163776293396950,-0.317538887262344,0.192484259605408,-0.224792823195457,-0.107778273522854,-0.012105301022530,0.100501418113708,0.024145621806383,0.025029562413692,-0.047893974930048) * FEATURE1_texOff(vec2(1,-1));
res += mat4(-0.196426138281822,0.110907666385174,-0.118809916079044,-0.026326062157750,-0.243914559483528,-0.198104932904243,-0.245711714029312,-0.332373529672623,-0.052010808140039,-0.190800130367279,-0.137936890125275,-0.171783834695816,-0.066228419542313,0.345157146453857,-0.262540668249130,-0.007057133596390) * FEATURE1_texOff(vec2(1,0));
res += mat4(0.158793881535530,0.080303512513638,-0.039926152676344,-0.027831967920065,-0.221126839518547,0.057379473000765,-0.766123592853546,-0.264656782150269,-0.143529251217842,0.039041280746460,-0.095450982451439,0.164951428771019,-0.120692253112793,-0.007644575554878,-0.184945523738861,-0.172398552298546) * FEATURE1_texOff(vec2(1,1));
res += mat4(0.093708723783493,-0.161621093750000,-0.017236318439245,0.006054388359189,-0.134261652827263,-0.139100730419159,-0.123737320303917,-0.214606761932373,-0.026619056239724,0.148514151573181,-0.027975263074040,0.066525645554066,-0.091956339776516,-0.069057166576385,-0.151386544108391,-0.136999234557152) * FEATURE2_texOff(vec2(-1,-1));
res += mat4(0.101458363234997,-0.140202313661575,0.096019737422466,0.072417557239532,-0.163954660296440,0.270085632801056,0.201220914721489,0.350884974002838,-0.154955968260765,-0.191070437431335,-0.004582974128425,0.062037665396929,-0.010296639986336,-0.038841109722853,0.088563516736031,0.102858155965805) * FEATURE2_texOff(vec2(-1,0));
res += mat4(-0.141716733574867,0.056775860488415,0.085712753236294,0.030255652964115,0.022110693156719,-0.028941530734301,0.100365459918976,-0.078396737575531,0.127258837223053,-0.007714294828475,0.079475551843643,-0.072033539414406,0.033361893147230,-0.089305028319359,-0.101498790085316,0.053903289139271) * FEATURE2_texOff(vec2(-1,1));
res += mat4(0.033822279423475,0.018585026264191,0.099838554859161,0.031037384644151,0.155307158827782,0.230427905917168,0.047610592097044,-0.189280867576599,-0.003508089343086,-0.083727665245533,-0.077960766851902,-0.140405222773552,-0.209913805127144,0.125004678964615,-0.200696468353271,-0.180019259452820) * FEATURE2_texOff(vec2(0,-1));
res += mat4(0.335523784160614,-0.074284523725510,0.173126429319382,-0.148867785930634,-0.068909518420696,-0.243623331189156,-0.343974530696869,-0.457472205162048,0.338673919439316,0.019177120178938,-0.003214538795874,0.039127480238676,-0.168740496039391,0.516745984554291,0.367506146430969,0.026967706158757) * FEATURE2_texOff(vec2(0,0));
res += mat4(-0.299755752086639,-0.329186618328094,-0.292979866266251,0.077775850892067,-0.164979815483093,-0.089994087815285,-0.072508245706558,-0.151606172323227,0.425666242837906,0.183179005980492,-0.053331859409809,0.051249388605356,0.119538165628910,0.261428505182266,0.081710301339626,0.034016601741314) * FEATURE2_texOff(vec2(0,1));
res += mat4(-0.164182573556900,0.036586474627256,-0.090330414474010,-0.174646750092506,-0.069974452257156,-0.175113797187805,0.007289906032383,-0.160919636487961,0.146828100085258,-0.054742332547903,0.007913995534182,-0.195969656109810,0.304187595844269,0.003055794630200,-0.131239548325539,-0.267573267221451) * FEATURE2_texOff(vec2(1,-1));
res += mat4(0.069284975528717,0.144918814301491,0.032050121575594,0.150073587894440,0.350909441709518,0.437773704528809,0.423747032880783,0.642541289329529,0.050722330808640,-0.060647103935480,-0.094325855374336,-0.024343011900783,0.220961004495621,0.254314720630646,0.112405411899090,0.159918606281281) * FEATURE2_texOff(vec2(1,0));
res += mat4(-0.001917584682815,-0.018507268279791,0.008030699566007,0.160109177231789,0.173473879694939,-0.022118955850601,0.129889756441116,0.115037947893143,-0.045358832925558,0.074061475694180,-0.102304406464100,-0.160583660006523,-0.225219815969467,-0.261995553970337,0.226284921169281,-0.174048602581024) * FEATURE2_texOff(vec2(1,1));
res += mat4(0.069679580628872,-0.104648068547249,-0.199843540787697,-0.011788805015385,0.064697884023190,0.124068051576614,0.012740951962769,0.006404404528439,-0.084463693201542,0.109641551971436,0.231226548552513,-0.009237877093256,0.295138537883759,0.071120254695415,0.175188764929771,-0.038911566138268) * FEATURE3_texOff(vec2(-1,-1));
res += mat4(0.078575514256954,-0.125625848770142,0.087900497019291,-0.187854260206223,0.012375856749713,-0.280960917472839,-0.137941986322403,-0.209415674209595,-0.004112019203603,0.218026563525200,0.648781895637512,0.179079174995422,-0.099869966506958,-0.520976603031158,-0.227779552340508,-0.203700304031372) * FEATURE3_texOff(vec2(-1,0));
res += mat4(-0.009508496150374,0.075217582285404,-0.102506399154663,0.012284331955016,0.021182235330343,0.117475427687168,-0.149955451488495,0.044187203049660,0.222916916012764,0.097744822502136,0.156771346926689,0.031677044928074,-0.110274180769920,-0.081868976354599,-0.093750774860382,-0.084018804132938) * FEATURE3_texOff(vec2(-1,1));
res += mat4(-0.175523772835732,0.096990853548050,-0.084211952984333,0.046886105090380,0.179863780736923,0.170132696628571,-0.071996092796326,-0.017815286293626,-0.108028464019299,-0.199936255812645,0.050712402909994,-0.045316793024540,0.255131483078003,-0.012619207613170,0.304027467966080,0.046768344938755) * FEATURE3_texOff(vec2(0,-1));
res += mat4(-0.182457104325294,0.493396013975143,0.354022920131683,0.483083575963974,0.046481806784868,-0.161630168557167,0.115393586456776,0.138448938727379,0.329495787620544,-0.041023563593626,0.434166729450226,-0.372150093317032,-0.289281636476517,-0.095172144472599,-0.383901447057724,-0.119460068643093) * FEATURE3_texOff(vec2(0,0));
res += mat4(0.111075595021248,-0.066247507929802,-0.043724432587624,-0.095852464437485,-0.062731459736824,0.053385980427265,0.027199940755963,-0.100132986903191,0.263907432556152,-0.124911233782768,0.159606933593750,0.132486298680305,-0.483667314052582,-0.020303718745708,-0.161071136593819,0.116611905395985) * FEATURE3_texOff(vec2(0,1));
res += mat4(-0.082786604762077,-0.059635978192091,-0.096906706690788,-0.107840009033680,-0.048826858401299,0.023935515433550,0.439428180456161,0.083781734108925,0.016642916947603,-0.161208301782608,-0.083429977297783,-0.020716844126582,0.117734350264072,-0.233978271484375,0.190370485186577,0.196994870901108) * FEATURE3_texOff(vec2(1,-1));
res += mat4(0.206390067934990,-0.290656089782715,0.038470800966024,0.008461328223348,-0.131875097751617,-0.422609001398087,0.479576706886292,0.176059886813164,0.097147323191166,-0.326293736696243,-0.146101623773575,-0.118932567536831,0.106584802269936,0.580698192119598,0.517559289932251,0.745481669902802) * FEATURE3_texOff(vec2(1,0));
res += mat4(0.121476210653782,0.115688472986221,-0.026239711791277,0.109962753951550,-0.022195259109139,-0.049675665795803,0.251935273408890,-0.054476354271173,0.120733104646206,-0.250193625688553,-0.105310469865799,-0.096522472798824,0.175301432609558,0.049930170178413,0.132103994488716,0.058050766587257) * FEATURE3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.824458956718445,0.264596134424210,0.063803829252720,0.554752290248871) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL1
//!BIND MODEL2
//!BIND MODEL3
//!SAVE MODEL4
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 2_1

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.007902535609901,0.119163453578949,0.054654505103827,0.111180879175663);
res += mat4(0.061324030160904,0.016569398343563,0.046839416027069,-0.073399916291237,-0.001374971237965,-0.006103523541242,-0.009438170120120,-0.022296950221062,0.078646130859852,0.100811325013638,-0.115444041788578,-0.097038418054581,0.292374432086945,-0.109601914882660,0.081548549234867,-0.022553708404303) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.276956051588058,-0.064556539058685,0.009479408152401,0.002472267718986,0.144854843616486,-0.063667066395283,0.095345839858055,-0.031355854123831,0.288032501935959,0.247934088110924,-0.211283072829247,0.356791257858276,0.005112199112773,0.114797495305538,-0.281632304191589,0.063897334039211) * MODEL1_texOff(vec2(-1,0));
res += mat4(-0.205311477184296,0.119963452219963,0.216321021318436,-0.017580702900887,0.047566059976816,-0.063351131975651,0.098024301230907,-0.110272832214832,-0.281092315912247,-0.148216873407364,0.121321395039558,0.099051080644131,-0.017433913424611,-0.021311357617378,-0.321274757385254,-0.243212088942528) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.048134095966816,-0.004745272919536,0.104563005268574,-0.145177111029625,-0.037299681454897,-0.035740237683058,-0.011257266625762,0.060536801815033,-0.159317582845688,0.072010889649391,-0.011440820991993,0.086580723524094,-0.194735124707222,0.024058757349849,-0.119494654238224,0.165006622672081) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.080628000199795,-0.424212962388992,0.074046865105629,-0.023762598633766,-0.042957704514265,-0.143994748592377,0.216480791568756,0.163143068552017,0.265457540750504,0.465810596942902,-0.103958450257778,0.300358027219772,-0.093796297907829,-0.122670255601406,0.343957036733627,-0.021904824301600) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.452952384948730,0.234881877899170,0.071142174303532,0.137228369712830,-0.080126404762268,-0.066580139100552,0.137807086110115,-0.180804371833801,0.023685455322266,-0.204603403806686,0.162241294980049,0.080218456685543,-0.004756537731737,0.001348000951111,0.321701914072037,-0.056554760783911) * MODEL1_texOff(vec2(0,1));
res += mat4(-0.151354327797890,-0.365870654582977,-0.077847406268120,-0.114068627357483,-0.007187124341726,-0.150347217917442,0.006702355109155,-0.056482560932636,0.045252647250891,0.099820874631405,0.151289775967598,0.085077404975891,0.141262277960777,0.038740724325180,-0.043431609869003,-0.127695813775063) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.286169320344925,-0.156704396009445,-0.369553238153458,-0.122042112052441,-0.113586299121380,-0.208170697093010,-0.096572674810886,-0.207147434353828,-0.249030813574791,-0.045517239719629,0.087848260998726,0.190163895487785,0.011040014214814,0.177330955862999,0.015526543371379,-0.020394865423441) * MODEL1_texOff(vec2(1,0));
res += mat4(0.116062477231026,-0.166767045855522,-0.134295359253883,-0.024784868583083,0.113279245793819,0.041875895112753,-0.126070633530617,-0.770539462566376,0.073391951620579,0.086175106465816,0.119671508669853,0.085393466055393,0.079758845269680,-0.020523274317384,0.213973924517632,-0.353606700897217) * MODEL1_texOff(vec2(1,1));
res += mat4(0.118313603103161,0.117807269096375,0.190293326973915,0.162676319479942,0.078704424202442,-0.210906848311424,0.045094877481461,-0.276389062404633,0.005187359638512,0.093555681407452,-0.028502771630883,0.088213257491589,-0.273000806570053,-0.332356810569763,-0.002575577935204,0.155407220125198) * MODEL2_texOff(vec2(-1,-1));
res += mat4(-0.458006888628006,0.049786068499088,0.420005947351456,-0.093070566654205,0.000199293208425,-0.214902818202972,0.051310487091541,-0.170786887407303,0.180916801095009,-0.187458202242851,0.208902806043625,-0.080286495387554,-0.116202704608440,0.194857895374298,-0.006848676595837,0.001653470331803) * MODEL2_texOff(vec2(-1,0));
res += mat4(0.089303143322468,0.033074494451284,-0.009991054423153,0.279162019491196,-0.171375080943108,0.014940989203751,-0.002243285300210,-0.271440804004669,-0.214320093393326,0.027654111385345,0.149801060557365,-0.050469953566790,0.095589518547058,-0.031312372535467,0.006564017850906,-0.053699005395174) * MODEL2_texOff(vec2(-1,1));
res += mat4(0.147271990776062,-0.031733926385641,0.051164131611586,0.014792175963521,0.022906906902790,-0.361656278371811,0.071378983557224,-0.148606300354004,-0.038267742842436,0.153250664472580,-0.025269510224462,-0.114951282739639,0.021951150149107,-1.071372032165527,0.066040918231010,0.001795427524485) * MODEL2_texOff(vec2(0,-1));
res += mat4(-0.223716571927071,-0.039304614067078,-0.348446518182755,0.363205403089523,0.039802379906178,0.181146204471588,0.197925448417664,0.566665649414063,0.577276945114136,-0.008416745811701,0.145963653922081,-0.022619325667620,-0.140327215194702,-0.015073126181960,0.000442340591690,-0.109627209603786) * MODEL2_texOff(vec2(0,0));
res += mat4(0.052894603461027,0.094088926911354,-0.181199878454208,0.092885226011276,0.054849039763212,-0.077219367027283,0.066606961190701,0.141110390424728,-0.094684541225433,-0.180760443210602,-0.043271046131849,0.006503004115075,-0.119984917342663,0.010061996057630,0.046530693769455,-0.001513563795015) * MODEL2_texOff(vec2(0,1));
res += mat4(0.190364956855774,-0.083217166364193,-0.051629822701216,0.099293246865273,-0.113533623516560,-0.164061486721039,0.025780128315091,-0.184439763426781,-0.010516283102334,0.206942066550255,0.014909861609340,-0.085392892360687,0.149674251675606,-0.069972112774849,-0.068256162106991,-0.044688336551189) * MODEL2_texOff(vec2(1,-1));
res += mat4(-0.196320056915283,0.032005123794079,0.022935051470995,0.257505923509598,-0.093605838716030,0.253251999616623,0.014284319244325,0.185582995414734,0.177439510822296,0.162919729948044,0.040156319737434,0.125858396291733,0.152486011385918,0.046071816235781,0.091890059411526,-0.015992829576135) * MODEL2_texOff(vec2(1,0));
res += mat4(0.009845591150224,0.170436277985573,0.009862831793725,0.024724781513214,0.137727096676826,-0.200427144765854,-0.141974017024040,0.070442155003548,-0.049926903098822,0.029186459258199,0.116118438541889,-0.109417364001274,0.018274948000908,-0.008778769522905,0.109363935887814,-0.120540447533131) * MODEL2_texOff(vec2(1,1));
res += mat4(-0.368281453847885,-0.077377922832966,-0.096514739096165,0.064855456352234,0.159528344869614,-0.107121236622334,0.070204004645348,-0.017513191327453,0.137259960174561,-0.096703104674816,-0.245970502495766,0.009796767495573,-0.087121792137623,0.056036282330751,-0.008283738046885,0.170136511325836) * MODEL3_texOff(vec2(-1,-1));
res += mat4(-0.461441129446030,0.138873755931854,-0.143602460622787,-0.023632701486349,0.234178125858307,-0.303539663553238,0.464608937501907,-0.100984685122967,-0.227516412734985,-0.049648359417915,-0.046651739627123,-0.229497373104095,-0.064048685133457,0.139566242694855,-0.151576399803162,0.652163982391357) * MODEL3_texOff(vec2(-1,0));
res += mat4(-0.025593010708690,-0.096682704985142,-0.279093950986862,-0.046306658536196,-0.157726854085922,0.126908481121063,0.159853696823120,-0.224684163928032,0.003307223785669,0.004399419762194,-0.069550469517708,-0.059423930943012,0.298835128545761,0.119780369102955,-0.017182994633913,0.231585949659348) * MODEL3_texOff(vec2(-1,1));
res += mat4(0.430696457624435,0.215752214193344,-0.014097883366048,0.200439929962158,-0.205391094088554,-0.211653470993042,0.025950539857149,0.105668522417545,0.172922506928444,-0.154995158314705,-0.235156714916229,-0.190526291728020,0.114269055426121,-0.106727339327335,0.077495396137238,0.050764493644238) * MODEL3_texOff(vec2(0,-1));
res += mat4(0.100911095738411,-0.111483886837959,0.208669424057007,-0.172000452876091,-0.005758863873780,0.268252432346344,-0.407552570104599,0.555968523025513,0.256042480468750,-0.115591511130333,0.350775361061096,-0.476092070341110,0.284091055393219,-0.076806455850601,-0.132501915097237,-0.327149838209152) * MODEL3_texOff(vec2(0,0));
res += mat4(-0.127868548035622,0.109417006373405,-0.011662142351270,-0.131107747554779,0.098763495683670,-0.090679943561554,-0.093680433928967,-0.184902176260948,-0.022931940853596,-0.030422795563936,0.008820227347314,-0.122441865503788,-0.160014286637306,-0.104134142398834,-0.204105332493782,0.335686385631561) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.020157197490335,0.246589750051498,0.050593700259924,0.099302254617214,-0.025617515668273,0.168329074978828,-0.002933933166787,0.048932939767838,-0.234536066651344,-0.101830668747425,0.293623298406601,0.034828126430511,-0.052714526653290,0.206061303615570,0.034495729953051,-0.094616048038006) * MODEL3_texOff(vec2(1,-1));
res += mat4(0.179745018482208,-0.059873223304749,-0.072604425251484,0.152430504560471,-0.018478007987142,0.051722250878811,-0.063727416098118,0.178473696112633,0.039762359112501,-0.058935306966305,0.139426127076149,-0.300905615091324,-0.023496719077229,-0.098684094846249,0.112931795418262,-0.059231717139482) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.012776048853993,0.129034310579300,0.016079457476735,-0.119285047054291,0.041345246136189,-0.007713257800788,0.182817488908768,-0.309105068445206,-0.004327253438532,-0.025931822136045,0.009191366843879,0.025256875902414,-0.216250196099281,-0.103930719196796,0.019581990316510,0.155027091503143) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.811981737613678,0.155287548899651,-0.233251869678497,-0.347386837005615) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.144075110554695,-0.057723153382540,0.104250222444534,0.186474144458771);
res += mat4(0.238374635577202,0.083396457135677,-0.048619117587805,0.016872657462955,-0.147187516093254,-0.421984225511551,0.046068862080574,-0.172507539391518,0.047628108412027,-0.149474233388901,-0.039496269077063,0.178550556302071,-0.024347066879272,-0.141580149531364,-0.002525890246034,0.210717692971230) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.050685148686171,-0.340201139450073,-0.013018129393458,0.063393749296665,-0.055575914680958,-0.204677090048790,-0.067270725965500,-0.079288236796856,-0.055091336369514,-0.200725257396698,0.060478713363409,-0.023338537663221,-0.302826881408691,0.180461749434471,-0.129950344562531,-0.017149399966002) * MODEL1_texOff(vec2(-1,0));
res += mat4(0.194132670760155,-0.084365837275982,-0.057601589709520,0.014488296583295,-0.176704674959183,-0.118935227394104,0.054166100919247,-0.000149015322677,0.173659354448318,-0.285169839859009,0.022103637456894,0.024819919839501,-0.103493727743626,-0.105540275573730,-0.100464545190334,0.095888592302799) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.279987692832947,-0.056282464414835,0.019985903054476,-0.041321840137243,0.211793914437294,0.284336954355240,-0.235593631863594,-0.103668458759785,-0.033655352890491,-0.160401403903961,0.010860589332879,-0.093102119863033,-0.194815278053284,-0.011011592112482,0.033526957035065,-0.473169624805450) * MODEL1_texOff(vec2(0,-1));
res += mat4(-0.485157370567322,-0.583296298980713,0.101062655448914,0.139226347208023,0.020424054935575,-0.189312919974327,0.065963685512543,0.194900572299957,-0.370632797479630,0.190989270806313,0.042596805840731,-0.446117520332336,-0.090663917362690,0.387125313282013,0.145142465829849,0.705214202404022) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.623684644699097,0.103942342102528,-0.087213799357414,-0.141032308340073,-0.291400074958801,0.147739723324776,-0.001245613559149,0.006888002157211,-0.028721733018756,-0.228676855564117,0.056883513927460,-0.159760460257530,0.192130133509636,-0.456827282905579,0.120456881821156,-0.803113400936127) * MODEL1_texOff(vec2(0,1));
res += mat4(0.234950900077820,0.087752178311348,0.286548107862473,0.122787527740002,-0.188092187047005,0.139538377523422,0.494918435811996,0.143134534358978,0.043922081589699,-0.239614740014076,-0.056163184344769,-0.082720659673214,-0.058557178825140,0.178961664438248,-0.169188797473907,-0.051934517920017) * MODEL1_texOff(vec2(1,-1));
res += mat4(-0.333776444196701,-0.128833204507828,0.581786513328552,0.350301653146744,-0.173426643013954,-0.001299121649936,0.157348632812500,0.007252423558384,-0.074084393680096,-0.110405012965202,0.067114308476448,-0.150085002183914,0.000149938336108,-0.018103893846273,0.113245502114296,-0.164235219359398) * MODEL1_texOff(vec2(1,0));
res += mat4(-0.266987264156342,-0.075648732483387,-0.042891670018435,0.059972263872623,-0.218421012163162,-0.063613571226597,-0.034336764365435,0.018142871558666,-0.064218357205391,-0.166249632835388,0.027020242065191,-0.163956120610237,0.271826028823853,0.037719782441854,0.045224137604237,0.151724472641945) * MODEL1_texOff(vec2(1,1));
res += mat4(0.129669144749641,-0.030601233243942,-0.061699140816927,-0.106116570532322,0.062289107590914,0.010506256483495,-0.048086810857058,-0.008957488462329,0.013127250596881,-0.166391387581825,-0.040326334536076,0.109435155987740,-0.092050999403000,0.090936996042728,-0.010118702426553,-0.016529880464077) * MODEL2_texOff(vec2(-1,-1));
res += mat4(-0.240493699908257,0.201255276799202,-0.122759200632572,-0.276587486267090,-0.057463977485895,0.147938296198845,-0.064113043248653,0.154636159539223,0.172191783785820,0.224959373474121,-0.161470010876656,0.050967227667570,-0.008735511451960,-0.102787569165230,0.042323391884565,0.045940335839987) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.153482943773270,0.233915805816650,-0.098396621644497,-0.207723885774612,-0.024002999067307,0.106334649026394,0.099674805998802,0.041920207440853,0.140239611268044,0.125390812754631,-0.055560983717442,0.020437942817807,-0.095355927944183,0.018728720024228,-0.186177179217339,-0.101404868066311) * MODEL2_texOff(vec2(-1,1));
res += mat4(0.102363169193268,0.030944315716624,0.020466342568398,0.078424394130707,-0.138740852475166,0.069901265203953,-0.117398567497730,0.025093803182244,0.129186153411865,0.006987416651100,0.081071369349957,-0.253189057111740,-0.067670240998268,-0.055637169629335,-0.110033027827740,0.144756510853767) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.561714112758636,-0.356716156005859,0.087719187140465,0.106097370386124,-0.174499869346619,-0.063699699938297,-0.019082114100456,0.243159502744675,-0.177149251103401,0.003333792090416,-0.173427596688271,0.254461795091629,-0.386873334646225,0.302266031503677,0.106262125074863,-0.465211182832718) * MODEL2_texOff(vec2(0,0));
res += mat4(0.309911429882050,0.030225947499275,0.030165581032634,0.032231874763966,-0.046751782298088,0.037239536643028,0.106969833374023,0.043642442673445,-0.039431992918253,-0.204904243350029,0.026106733828783,-0.199596360325813,0.097464136779308,-0.319529116153717,0.084815353155136,0.198763981461525) * MODEL2_texOff(vec2(0,1));
res += mat4(0.009943938814104,0.240605965256691,0.038501530885696,0.040984962135553,0.089819751679897,0.214321509003639,-0.502705216407776,-0.022051306441426,0.097261838614941,0.231071576476097,0.110863015055656,0.028159312903881,-0.101059347391129,0.020662313327193,0.040969122201204,-0.022575432434678) * MODEL2_texOff(vec2(1,-1));
res += mat4(0.188778415322304,0.184870064258575,0.116710171103477,0.045591019093990,-0.538772106170654,-0.196687385439873,-0.859963834285736,-0.121405862271786,0.118918247520924,-0.005646353587508,-0.433650463819504,0.096480891108513,-0.139583811163902,0.226736024022102,0.193261712789536,-0.107749320566654) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.051220253109932,0.264090448617935,-0.037505801767111,-0.106974504888058,-0.209974542260170,0.298005878925323,-0.069772869348526,-0.197992384433746,-0.186415478587151,-0.074303403496742,0.115562297403812,0.095189489424229,0.062027353793383,-0.164295732975006,0.068376347422600,0.020953126251698) * MODEL2_texOff(vec2(1,1));
res += mat4(0.033356528729200,0.183359414339066,0.009560588747263,-0.061660535633564,0.155950963497162,-0.102352738380432,0.178036168217659,0.192324057221413,-0.230327978730202,0.089936405420303,-0.090185321867466,-0.127652853727341,-0.034344717860222,-0.272092491388321,-0.167689055204391,-0.141692727804184) * MODEL3_texOff(vec2(-1,-1));
res += mat4(-0.041391838341951,-0.093620523810387,0.169659912586212,-0.046861324459314,-0.377226889133453,0.155008286237717,-0.116315603256226,-0.178005158901215,-0.489309817552567,-0.060024410486221,0.049936469644308,0.189765945076942,-0.099320605397224,-0.069953255355358,-0.094683870673180,-0.310360670089722) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.204085081815720,-0.237391024827957,-0.023454699665308,0.189934358000755,-0.214679077267647,0.123687058687210,0.018515123054385,-0.235187277197838,-0.251432269811630,-0.060136556625366,0.038832228630781,0.051436901092529,-0.559012115001678,-0.016923004761338,-0.049921523779631,0.072003737092018) * MODEL3_texOff(vec2(-1,1));
res += mat4(-0.126946151256561,0.212523072957993,0.028979128226638,0.244401335716248,-0.064649634063244,-0.028339618816972,0.475458770990372,0.286966890096664,-0.002393229631707,-0.115164451301098,-0.171914353966713,0.232078298926353,0.090542837977409,0.270905137062073,-0.005953984335065,-0.213329598307610) * MODEL3_texOff(vec2(0,-1));
res += mat4(0.210077792406082,-0.348139971494675,0.050034854561090,0.016739798709750,-0.063768737018108,0.368704587221146,0.557817339897156,-0.172424286603928,0.541588187217712,-0.306184709072113,-0.156939744949341,0.025304293259978,-0.203593224287033,0.000977965071797,0.196559771895409,0.006708085536957) * MODEL3_texOff(vec2(0,0));
res += mat4(-0.370908230543137,-0.182524800300598,0.007938262075186,-0.411449402570724,-0.056809633970261,-0.423171818256378,0.066613413393497,0.192140504717827,-0.088047154247761,-0.154775217175484,-0.063839703798294,-0.084983572363853,-0.064034096896648,-0.015487583354115,-0.137784421443939,-0.001836334588006) * MODEL3_texOff(vec2(0,1));
res += mat4(0.038545385003090,-0.266418159008026,-0.150549963116646,-0.105873316526413,0.053056057542562,-0.178958788514137,-0.195862710475922,-0.015476815402508,-0.007804236374795,-0.172379299998283,0.198480099439621,0.093013532459736,-0.069067806005478,0.152024954557419,0.153066694736481,-0.009335954673588) * MODEL3_texOff(vec2(1,-1));
res += mat4(0.139448314905167,-0.103170014917850,-0.034165143966675,0.075944229960442,-0.008443364873528,0.229277819395065,-0.279111325740814,-0.124471604824066,0.355388194322586,0.107241228222847,0.301434546709061,0.255804330110550,0.126136839389801,-0.408216387033463,-0.019031032919884,0.174247249960899) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.080401495099068,0.005891956854612,-0.005020283162594,0.201268419623375,0.009391847997904,-0.039284497499466,-0.203641608357430,0.071056462824345,0.174122467637062,-0.071774847805500,0.129817217588425,0.033313382416964,0.249618276953697,0.018234318122268,0.198092311620712,0.165188297629356) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.191363483667374,0.614398241043091,-0.296823590993881,0.817667245864868) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL1
//!BIND MODEL2
//!BIND MODEL3
//!SAVE MODEL5
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 2_2

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.140746191143990,0.095361746847630,0.070506349205971,0.019337471574545);
res += mat4(-0.048093773424625,0.073294095695019,-0.023714097216725,0.205325737595558,0.040134288370609,-0.064160600304604,-0.018880039453506,0.056727327406406,-0.123920060694218,-0.007555997464806,-0.034886654466391,-0.074380531907082,-0.039067346602678,0.191884100437164,0.103221125900745,-0.259503692388535) * MODEL1_texOff(vec2(-1,-1));
res += mat4(-0.101057529449463,0.217497766017914,0.156941369175911,-0.202374786138535,0.011551196686924,-0.034664086997509,-0.057894542813301,-0.059860460460186,0.061593852937222,0.002755349501967,0.150713965296745,-0.118083037436008,0.149743661284447,-0.042065925896168,-0.097828231751919,0.144634276628494) * MODEL1_texOff(vec2(-1,0));
res += mat4(-0.125353351235390,0.095762722194195,0.032473463565111,-0.108023174107075,0.056132633239031,0.165496647357941,0.045795973390341,-0.013829637318850,0.169638827443123,0.036325432360172,0.172329604625702,0.057797100394964,0.019820194691420,0.113003626465797,0.070064730942249,0.128077358007431) * MODEL1_texOff(vec2(-1,1));
res += mat4(-0.017290040850639,-0.086195386946201,0.041100978851318,-0.050664745271206,0.061460368335247,-0.139935106039047,0.042615305632353,0.038131974637508,-0.161599606275558,-0.152186706662178,-0.193305090069771,-0.089119739830494,0.032101534307003,0.349386274814606,0.028416251763701,0.094675652682781) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.151592105627060,0.528524637222290,0.080244511365891,-0.159753337502480,-0.184146225452423,-0.069050356745720,-0.192819610238075,-0.016350284218788,-0.926637232303619,-0.556639194488525,0.240126758813858,-0.091342732310295,0.579509556293488,-0.023555178195238,0.131961733102798,0.057399254292250) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.091722346842289,-0.267217338085175,-0.535856902599335,-0.141371592879295,0.247028768062592,0.132617294788361,0.334738463163376,0.008696221746504,0.484612435102463,-0.122640654444695,0.496490836143494,0.327020883560181,0.092551156878471,0.057964853942394,0.230908751487732,0.231487616896629) * MODEL1_texOff(vec2(0,1));
res += mat4(0.027462005615234,0.065509058535099,0.172704651951790,-0.396243810653687,-0.014671853743494,0.010143979452550,0.051873795688152,-0.044091239571571,0.151155710220337,0.090801887214184,0.005719356704503,0.062208298593760,0.126588955521584,-0.055158257484436,0.130045160651207,-0.019812103360891) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.227802604436874,0.021223543211818,0.143935948610306,-0.023420082405210,0.106295645236969,-0.148214504122734,-0.222596064209938,0.113637045025826,0.310781896114349,0.247234940528870,0.055518850684166,0.164195701479912,-0.098712287843227,-0.106930851936340,-0.051379568874836,-0.277090162038803) * MODEL1_texOff(vec2(1,0));
res += mat4(0.116825595498085,-0.051964677870274,-0.130719378590584,0.264537960290909,0.166272863745689,-0.077212177217007,0.020037820562720,0.166511312127113,0.251124888658524,-0.084834784269333,0.078006103634834,-0.120263367891312,-0.142099440097809,-0.078089237213135,0.206216424703598,-0.056543063372374) * MODEL1_texOff(vec2(1,1));
res += mat4(-0.084155343472958,-0.097019873559475,-0.086279347538948,-0.143442451953888,0.204143181443214,-0.050179220736027,-0.017582304775715,0.078322328627110,-0.100565604865551,0.069330818951130,-0.094336576759815,0.334943234920502,0.153076902031898,0.095476157963276,0.127857044339180,0.095826640725136) * MODEL2_texOff(vec2(-1,-1));
res += mat4(0.159113332629204,-0.605148792266846,0.467806756496429,0.232089757919312,0.522994637489319,0.414373010396957,-0.002664563478902,0.077917136251926,-0.011033269576728,-0.119456574320793,-0.024398874491453,-0.176373571157455,0.017937405034900,-0.202413573861122,-0.484182447195053,-0.112178653478622) * MODEL2_texOff(vec2(-1,0));
res += mat4(0.057683683931828,-0.040286231786013,-0.143736422061920,-0.056335024535656,0.099464029073715,-0.055742163211107,-0.163238510489464,-0.162530317902565,-0.008013158105314,0.076874382793903,0.091073587536812,-0.114047907292843,0.027806177735329,0.042072378098965,-0.035547427833080,0.015357539989054) * MODEL2_texOff(vec2(-1,1));
res += mat4(-0.138016864657402,-0.039096195250750,-0.016890333965421,0.015629164874554,0.243693456053734,0.020455364137888,0.155742958188057,0.091714940965176,0.086188144981861,0.077595293521881,-0.161749616265297,0.045849006623030,0.045743633061647,0.084886625409126,0.123288467526436,-0.232550397515297) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.241879031062126,0.463867992162704,-0.011127776466310,0.298935621976852,-0.449517399072647,-0.509107291698456,-0.363391458988190,-0.024658920243382,0.066670976579189,-0.591062128543854,-0.359733164310455,-0.483867019414902,-0.068458199501038,-0.404796004295349,-0.711940824985504,-0.163475319743156) * MODEL2_texOff(vec2(0,0));
res += mat4(0.016869394108653,-0.061238590627909,0.054452572017908,-0.105955608189106,-0.101519696414471,-0.289525210857391,0.035349082201719,-0.069898277521133,-0.099703624844551,0.387667119503021,0.398371577262878,0.251479059457779,-0.029889382421970,0.048650071024895,-0.040431164205074,-0.025980392470956) * MODEL2_texOff(vec2(0,1));
res += mat4(-0.083913952112198,0.023501912131906,-0.023529032245278,-0.087893843650818,-0.000398905685870,0.085377283394337,0.049137052148581,0.206607803702354,0.083032354712486,-0.084596715867519,0.092176795005798,-0.555871546268463,-0.174328148365021,0.175513550639153,0.030260326340795,-0.418560624122620) * MODEL2_texOff(vec2(1,-1));
res += mat4(-0.118333771824837,0.135547816753387,0.023021107539535,0.131596788764000,0.003536691423506,-0.071060076355934,-0.150489211082458,-0.160006269812584,0.067398801445961,-0.181996196508408,-0.175849676132202,-0.138363957405090,-0.048340924084187,-0.124943450093269,-0.003397792344913,0.248993933200836) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.124847620725632,0.091446951031685,0.024213245138526,-0.117407478392124,-0.073002897202969,-0.078343912959099,0.021569978445768,0.011580118909478,0.070137411355972,0.010240796953440,-0.023799542337656,0.506749689579010,0.027088904753327,-0.025312641635537,0.025177700445056,0.041625667363405) * MODEL2_texOff(vec2(1,1));
res += mat4(0.117851026356220,-0.082006134092808,0.071942061185837,-0.013433663174510,-0.066070593893528,0.034227076917887,-0.076494991779327,0.111293710768223,0.094956628978252,0.045895412564278,0.004103239625692,0.042060270905495,-0.109933279454708,0.115063026547432,-0.007638703100383,-0.075362667441368) * MODEL3_texOff(vec2(-1,-1));
res += mat4(-0.116746149957180,-0.050571709871292,0.027346700429916,-0.038502596318722,-0.044604636728764,0.513822615146637,0.061694215983152,-0.231667220592499,0.148956403136253,-0.026375778019428,-0.003298782976344,-0.042406927794218,-0.079580925405025,0.068058960139751,-0.112418107688427,0.017680130898952) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.071266598999500,-0.071030393242836,-0.179885700345039,0.024074304848909,0.030679153278470,-0.234202504158020,0.072598867118359,-0.111900061368942,0.190138354897499,0.022934410721064,-0.189334303140640,0.029168032109737,-0.158313021063805,-0.023465972393751,0.033629242330790,-0.017173537984490) * MODEL3_texOff(vec2(-1,1));
res += mat4(-0.114151306450367,-0.239837989211082,-0.152021586894989,-0.079315625131130,-0.180995434522629,0.074392668902874,-0.217291951179504,-0.179262623190880,0.109754562377930,0.024531658738852,0.191717430949211,-0.245129004120827,0.142632663249969,-0.227910429239273,-0.165684863924980,0.018250014632940) * MODEL3_texOff(vec2(0,-1));
res += mat4(-0.003304383950308,0.581923067569733,0.492425620555878,0.182543084025383,-0.355566829442978,-0.552838921546936,0.016582245007157,0.025048101320863,0.039444863796234,-0.194947063922882,-0.036908067762852,-0.061601828783751,0.375305682420731,-0.764915287494659,0.342675566673279,-0.072069033980370) * MODEL3_texOff(vec2(0,0));
res += mat4(0.142055332660675,-0.290942102670670,-0.393689334392548,0.014786177314818,0.217254072427750,0.217718496918678,0.423922300338745,0.172255173325539,0.153476133942604,0.150778070092201,-0.214596211910248,0.000926552282181,-0.063718356192112,0.063396379351616,-0.027290573343635,-0.348455429077148) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.062774628400803,0.042682532221079,-0.070242397487164,0.156831577420235,-0.059428542852402,0.017786439508200,-0.113951042294502,-0.237216070294380,0.073743686079979,0.108212865889072,0.154110506176949,-0.026881216093898,-0.095690079033375,0.122625961899757,-0.120534330606461,0.109429329633713) * MODEL3_texOff(vec2(1,-1));
res += mat4(0.024582302197814,-0.198113724589348,-0.020346885547042,-0.065365739166737,-0.031071016564965,0.478672027587891,0.026004839688540,0.026940334588289,0.035809699445963,-0.201845318078995,-0.182696476578712,-0.207818388938904,0.349045872688293,-0.039037607610226,0.097914725542068,0.028204502537847) * MODEL3_texOff(vec2(1,0));
res += mat4(0.074553132057190,-0.230192273855209,-0.058336708694696,-0.233642637729645,-0.076026551425457,-0.105603992938995,0.220526933670044,0.197408854961395,-0.088237360119820,0.024399923160672,-0.129093557596207,0.128577560186386,-0.046267535537481,0.039757110178471,-0.127198889851570,-0.087107658386230) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.377387493848801,0.802334785461426,-0.389738529920578,-0.518427550792694) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.152339622378349,0.096906490623951,0.001133278128691,0.158482849597931);
res += mat4(0.008638472296298,0.065778084099293,0.332867264747620,-0.272654980421066,0.141126826405525,-0.014426462352276,0.069377794861794,0.579159438610077,0.079199686646461,-0.009040656499565,-0.229904651641846,-0.447323411703110,0.038712564855814,-0.031271893531084,-0.090900979936123,-0.087805174291134) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.020498676225543,0.006146339233965,0.236294612288475,0.301424831151962,0.127924457192421,-0.167619109153748,-0.577205657958984,-0.027287906035781,-0.134872227907181,-0.055841688066721,0.047761060297489,-0.253540396690369,-0.083720140159130,0.108778312802315,0.251172631978989,-0.166198179125786) * MODEL1_texOff(vec2(-1,0));
res += mat4(0.024782232940197,-0.020432511344552,-0.110345177352428,-0.113824285566807,0.001623437856324,-0.200039759278297,0.046684548258781,0.101540625095367,0.024738980457187,0.018342152237892,-0.234247729182243,-0.101817950606346,0.069122612476349,-0.056863505393267,-0.245577543973923,-0.048969145864248) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.003529263660312,-0.018623879179358,0.109779931604862,0.038026027381420,0.194582283496857,-0.250443935394287,-0.158520638942719,0.380864024162292,0.050228737294674,-0.004731130786240,0.124109946191311,-0.289951622486115,-0.261902183294296,-0.246154457330704,0.088747292757034,0.031885053962469) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.167761012911797,0.141035884618759,-0.381094604730606,0.564204454421997,-0.113255321979523,-0.060855064541101,-0.232916653156281,-0.096024423837662,0.000350789836375,-0.147309929132462,0.116924546658993,-0.346970617771149,0.145699396729469,0.511954724788666,-0.493116766214371,0.291229724884033) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.028620537370443,0.487375020980835,0.046989679336548,-0.025436617434025,-0.014784724451602,0.011243966408074,-0.081153273582458,0.163209632039070,-0.226358026266098,-0.096997298300266,0.048164721578360,-0.308523565530777,0.036088142544031,-0.679592132568359,-0.083064705133438,0.076930791139603) * MODEL1_texOff(vec2(0,1));
res += mat4(0.037171885371208,0.015977418050170,0.146440029144287,-0.110273748636246,0.037568643689156,0.076522924005985,-0.164779990911484,0.159381568431854,-0.012175984680653,-0.048390753567219,-0.030346125364304,-0.081921547651291,0.092321172356606,0.128388911485672,0.029124753549695,0.040254496037960) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.015033205039799,0.084595896303654,0.197511762380600,-0.139466822147369,0.093550249934196,0.140987753868103,-0.248916298151016,-0.053743399679661,-0.076391950249672,0.034224364906549,0.046625275164843,-0.046190213412046,-0.277506232261658,0.038199823349714,0.212522938847542,-0.300060033798218) * MODEL1_texOff(vec2(1,0));
res += mat4(0.144891828298569,-0.048346262425184,0.095684386789799,-0.015343352220953,0.094981685280800,-0.090150073170662,-0.118823617696762,0.082971692085266,-0.031004950404167,0.044954966753721,0.158300384879112,-0.028816131874919,-0.062490589916706,-0.138366818428040,0.220006600022316,-0.176099225878716) * MODEL1_texOff(vec2(1,1));
res += mat4(-0.060468550771475,0.030937433242798,0.328565239906311,-0.136933654546738,-0.020885929465294,-0.028080012649298,-0.187591210007668,0.053692106157541,0.124243639409542,-0.010751624591649,0.018265955150127,0.189881354570389,-0.061776250600815,0.052548892796040,0.075228631496429,0.000708362436853) * MODEL2_texOff(vec2(-1,-1));
res += mat4(-0.162968099117279,-0.004115136340261,0.628725886344910,-0.161684215068817,-0.230537518858910,-0.059577085077763,-0.712329864501953,-0.252019464969635,0.069777376949787,0.009834618307650,0.073283754289150,-0.144808098673820,0.118270292878151,-0.142363861203194,-0.494919270277023,0.005905092693865) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.052803214639425,-0.124250747263432,-0.078598797321320,-0.281657218933105,-0.099433220922947,-0.011862881481647,-0.011847767047584,0.031607743352652,-0.140785738825798,0.216930285096169,-0.232426837086678,-0.145477101206779,-0.125736817717552,-0.078754454851151,0.623797893524170,0.428004860877991) * MODEL2_texOff(vec2(-1,1));
res += mat4(0.120195239782333,0.235620960593224,-0.016818685457110,-0.166135489940643,-0.046447463333607,0.040213283151388,-0.355485349893570,-0.277680128812790,-0.192298427224159,-0.106508530676365,-0.029260812327266,0.188648983836174,0.049076277762651,0.077295243740082,-0.030337164178491,-0.170470461249352) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.088030181825161,-0.031498763710260,-0.168859079480171,-0.049315914511681,0.261475592851639,0.113300278782845,0.256622970104218,-0.167000472545624,-0.209269911050797,0.343958705663681,0.146713420748711,-0.394209206104279,-0.125883430242538,-0.416340202093124,0.261639773845673,0.240838110446930) * MODEL2_texOff(vec2(0,0));
res += mat4(-0.186992213129997,-0.156496226787567,0.073480091989040,-0.143019378185272,-0.010118286125362,-0.169643059372902,0.519134044647217,0.002872986020520,0.229529961943626,-0.716766119003296,0.230631411075592,0.134838417172432,0.379670143127441,0.188894167542458,-0.496898323297501,0.296252340078354) * MODEL2_texOff(vec2(0,1));
res += mat4(-0.054225865751505,0.325288683176041,-0.111672848463058,-0.169464975595474,0.075707145035267,0.042574428021908,0.065905131399632,-0.055766399949789,-0.097417436540127,-0.081879079341888,0.102532252669334,0.044369462877512,0.020771512761712,0.008385105058551,-0.033911395817995,0.006006256677210) * MODEL2_texOff(vec2(1,-1));
res += mat4(-0.034944493323565,-0.068009205162525,0.146964907646179,-0.095295526087284,0.064951695501804,-0.261779844760895,-0.065856114029884,-0.154160216450691,-0.025101521983743,0.039343044161797,0.079445637762547,-0.237973600625992,-0.067977420985699,-0.096711568534374,-0.083023943006992,0.004468900151551) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.108135625720024,-0.190484911203384,0.070568606257439,0.057293049991131,0.038368046283722,-0.129012450575829,0.205842196941376,0.067298799753189,0.012913639657199,-0.347787201404572,-0.045190408825874,-0.094945751130581,-0.268486559391022,-0.024543063715100,0.017704958096147,-0.127130895853043) * MODEL2_texOff(vec2(1,1));
res += mat4(-0.188601866364479,0.072127453982830,0.138187274336815,-0.153713598847389,0.082776650786400,0.121635884046555,0.115815065801144,0.139913380146027,-0.241900518536568,0.018482610583305,0.088635824620724,-0.076784498989582,-0.091659545898438,-0.249487847089767,-0.109216839075089,0.139561384916306) * MODEL3_texOff(vec2(-1,-1));
res += mat4(-0.028017465025187,-0.166883558034897,-0.205552250146866,0.301018506288528,-1.145034670829773,-0.226272270083427,0.238800927996635,-0.318766146898270,-0.066956587135792,0.028081929311156,0.350565671920776,-0.238793909549713,-0.512353062629700,-0.112607657909393,0.298221796751022,-0.848612964153290) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.035336192697287,-0.222176954150200,-0.279795080423355,-0.171739935874939,-0.097559787333012,0.152195155620575,-0.030398551374674,0.256865680217743,0.115326590836048,0.024817856028676,-0.317136168479919,-0.117053635418415,-0.126101702451706,0.198005735874176,0.042068488895893,-0.087896898388863) * MODEL3_texOff(vec2(-1,1));
res += mat4(0.205921083688736,0.289249420166016,-0.061382468789816,-0.292466521263123,0.093056395649910,0.087244547903538,-0.144553571939468,-0.163387611508369,0.282626330852509,0.286441326141357,-0.260610103607178,-0.128515705466270,-0.008096273057163,-0.074620254337788,0.275336354970932,0.150973707437515) * MODEL3_texOff(vec2(0,-1));
res += mat4(0.527085125446320,-0.459778606891632,-0.135795116424561,0.568663239479065,0.045971389859915,-0.049970559775829,-0.039882399141788,-0.229684412479401,0.352166742086411,0.297923147678375,0.111837364733219,0.248022869229317,0.164593607187271,0.008305230177939,0.365935504436493,0.294005066156387) * MODEL3_texOff(vec2(0,0));
res += mat4(0.014578958041966,-0.424497127532959,0.436130076646805,-0.018859297037125,-0.007526753470302,-0.242140725255013,-0.181698530912399,-0.145753622055054,-0.154898658394814,-0.048051811754704,0.051955036818981,-0.074069246649742,0.072141289710999,0.154661118984222,0.048587188124657,0.019773323088884) * MODEL3_texOff(vec2(0,1));
res += mat4(0.041030555963516,0.016045326367021,-0.041433330625296,0.133967116475105,0.090023122727871,0.054704159498215,0.017278166487813,0.026836119592190,0.125354200601578,0.102944634854794,-0.111849740147591,-0.013867491856217,-0.078389979898930,-0.124462202191353,0.070061057806015,0.071165390312672) * MODEL3_texOff(vec2(1,-1));
res += mat4(-0.294011861085892,-0.055796835571527,0.056815128773451,-0.269323050975800,-0.137134850025177,0.007232790812850,0.195683687925339,-0.082299225032330,-0.194472581148148,0.064595185220242,0.093658819794655,0.087060004472733,0.138736829161644,0.043438706547022,-0.196343824267387,-0.069134764373302) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.103947110474110,-0.029247172176838,-0.057031102478504,-0.142273828387260,0.043554391711950,0.137953862547874,-0.078636206686497,-0.024847308173776,0.008089344017208,-0.073498688638210,0.174531981348991,-0.164385870099068,-0.082661703228951,-0.048127923160791,0.081345118582249,-0.106233298778534) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.448847621679306,-0.325093418359756,0.103579111397266,0.863402664661407) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL1
//!BIND MODEL2
//!BIND MODEL3
//!SAVE MODEL6
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 2_3

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.060080226510763,0.017093053087592,0.009418633766472,0.003766727400944);
res += mat4(0.113928049802780,0.017533132806420,0.033132415264845,0.016900556162000,-0.028482766821980,-0.036838721483946,-0.001015814836137,-0.049543447792530,-0.058789879083633,-0.103235743939877,0.061946269124746,-0.271792918443680,-0.130996644496918,-0.021350832656026,0.076142035424709,-0.101423323154449) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.108341433107853,0.274004399776459,-0.181877687573433,0.042114242911339,-0.004305447917432,0.119347631931305,-0.078025236725807,0.111672781407833,-0.103377476334572,-0.020382160320878,0.253427356481552,-0.256993114948273,-0.175989806652069,-0.043251667171717,0.343392699956894,-0.309435665607452) * MODEL1_texOff(vec2(-1,0));
res += mat4(-0.117683254182339,-0.089878670871258,-0.324590981006622,0.085240662097931,0.050253558903933,0.058944761753082,-0.237176403403282,-0.103179998695850,0.120223730802536,-0.128475278615952,0.037627179175615,-0.000910122704227,0.157318428158760,0.025508461520076,-0.045660328119993,0.114544846117496) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.155215352773666,0.081061825156212,-0.032375529408455,-0.083060383796692,-0.049381308257580,0.022738128900528,0.053640637546778,0.062879949808121,0.009208513423800,0.024201737716794,0.132297843694687,-0.347158253192902,-0.184101209044456,-0.065144553780556,0.038787316530943,-0.309199720621109) * MODEL1_texOff(vec2(0,-1));
res += mat4(-0.281665742397308,-0.011759642511606,-0.399371922016144,0.203274652361870,-0.587680757045746,0.046296041458845,-0.237607613205910,-0.320643126964569,0.292740434408188,-0.203983858227730,0.635194301605225,0.977478384971619,0.458096504211426,0.240788653492928,-0.207124471664429,0.643614172935486) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.345321029424667,-0.584121584892273,-0.088786713778973,-0.169076949357986,0.334043174982071,0.000798837922048,-0.297462433576584,0.029778731986880,0.140258356928825,0.335224241018295,0.271334946155548,0.196745678782463,-0.114386074244976,-0.139406293630600,-0.093718424439430,0.056630033999681) * MODEL1_texOff(vec2(0,1));
res += mat4(0.022466490045190,0.065923750400543,-0.048351414501667,0.143396317958832,0.196858555078506,0.027307793498039,-0.023836731910706,0.146047487854958,0.190300792455673,0.032107967883348,-0.056113742291927,-0.028408298268914,-0.112958781421185,0.027269087731838,-0.121951542794704,-0.029191579669714) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.018722767010331,0.190663114190102,0.233147427439690,-0.284970760345459,0.198958516120911,0.018894689157605,0.163795456290245,-0.221863582730293,0.213877648115158,0.163345813751221,-0.358020931482315,-0.042258094996214,-0.373550593852997,0.023778179660439,0.011896878480911,-0.336166083812714) * MODEL1_texOff(vec2(1,0));
res += mat4(0.010158890858293,0.026742607355118,0.048152279108763,-0.173806369304657,0.551186919212341,0.005700965877622,0.020304378122091,0.131334349513054,-0.034387677907944,0.033365931361914,-0.073070868849754,0.135594129562378,0.331235408782959,-0.028874417766929,-0.217289939522743,-0.000236912441324) * MODEL1_texOff(vec2(1,1));
res += mat4(0.094746522605419,-0.123631179332733,0.022820279002190,-0.138918504118919,-0.058661181479692,-0.132173523306847,-0.108471155166626,0.263879567384720,0.169371172785759,0.015769660472870,-0.139198482036591,-0.122670061886311,-0.065984204411507,0.119488582015038,0.042787071317434,0.145358562469482) * MODEL2_texOff(vec2(-1,-1));
res += mat4(0.052665613591671,-0.253398030996323,-0.037385098636150,0.222298353910446,-0.090887270867825,-0.042135532945395,-0.235967099666595,-0.224653422832489,-0.075014069676399,0.655151665210724,-0.151466548442841,-0.047089070081711,-0.351692229509354,0.299445569515228,0.047233905643225,0.027891429141164) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.183655843138695,0.109260946512222,-0.012623630464077,-0.040660493075848,-0.047089856117964,-0.087817579507828,-0.148389145731926,0.183704644441605,0.157370552420616,-0.373933255672455,-0.226265490055084,-0.107288412749767,0.021407850086689,0.064953245222569,0.076356947422028,0.016691051423550) * MODEL2_texOff(vec2(-1,1));
res += mat4(-0.443501591682434,0.073429264128208,0.023999145254493,0.120965115725994,-0.162062928080559,0.159091785550117,-0.135207325220108,0.053228717297316,-0.128029912710190,-0.042414691299200,0.173273473978043,-0.034190732985735,-0.422117531299591,-0.011287540197372,-0.055714361369610,0.126830592751503) * MODEL2_texOff(vec2(0,-1));
res += mat4(-1.147684216499329,-0.132558956742287,0.181923717260361,-0.601189792156219,0.033138543367386,-0.177996218204498,-0.347430318593979,0.182384014129639,0.374323010444641,0.209275692701340,-0.138402447104454,0.173131138086319,-0.072758346796036,-0.530546128749847,-0.114026620984077,-0.373648822307587) * MODEL2_texOff(vec2(0,0));
res += mat4(-0.341495215892792,0.040223404765129,-0.031796857714653,0.063638210296631,-0.042227629572153,0.229814723134041,0.046506695449352,-0.104857131838799,0.066537797451019,-0.444710701704025,0.109569899737835,0.243655622005463,-0.052237708121538,-0.277605921030045,-0.017236545681953,0.158394798636436) * MODEL2_texOff(vec2(0,1));
res += mat4(-0.140919044613838,-0.002193664666265,0.011889192275703,0.019776022061706,-0.085461489856243,0.089218698441982,-0.031875330954790,0.004470356274396,-0.224654287099838,-0.023885069414973,0.102456986904144,0.016709199175239,0.066776894032955,0.022559812292457,0.045457180589437,0.225615516304970) * MODEL2_texOff(vec2(1,-1));
res += mat4(-0.158982306718826,-0.115728490054607,-0.064128644764423,-0.059605736285448,-0.193301945924759,0.065905362367630,0.115574277937412,-0.073804318904877,0.170470491051674,-0.018079170957208,0.054066896438599,0.250873208045959,-0.114995859563351,0.064953245222569,0.141419738531113,-0.057115893810987) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.013667725026608,0.070537239313126,-0.064737804234028,-0.098834581673145,-0.239513754844666,-0.125915244221687,0.112775638699532,-0.175441578030586,0.048341035842896,0.117975652217865,-0.077415466308594,-0.053286340087652,0.142323046922684,0.236037343740463,-0.043661180883646,-0.013365449383855) * MODEL2_texOff(vec2(1,1));
res += mat4(0.139265149831772,0.023641755804420,0.069787986576557,-0.055217608809471,0.025534829124808,0.228904739022255,-0.134329259395599,0.160456717014313,-0.014071553014219,-0.028399858623743,0.055029958486557,0.132227346301079,-0.037913799285889,0.063610345125198,0.018617091700435,-0.117101624608040) * MODEL3_texOff(vec2(-1,-1));
res += mat4(0.162847533822060,-0.509936511516571,0.534218370914459,-0.005576400086284,-0.061686392873526,0.106461487710476,-0.545936942100525,0.128053992986679,-0.093662612140179,-0.262279570102692,0.049810487776995,0.220502570271492,-0.579837739467621,0.198313027620316,0.206633850932121,-0.398293107748032) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.187271490693092,0.098488211631775,0.126471906900406,0.126106709241867,0.134426698088646,-0.162294313311577,-0.343470156192780,0.016236236318946,0.066624693572521,0.323710322380066,0.109099641442299,0.105411253869534,-0.210075929760933,-0.000024775652491,0.094789274036884,-0.060026552528143) * MODEL3_texOff(vec2(-1,1));
res += mat4(0.068896815180779,-0.004004851449281,0.013512649573386,-0.126060217618942,-0.270385921001434,0.046354297548532,0.103425934910774,-0.074793919920921,0.149484366178513,-0.026140529662371,0.070973128080368,0.200679644942284,0.020835485309362,-0.008626791648567,0.053559694439173,-0.335235863924026) * MODEL3_texOff(vec2(0,-1));
res += mat4(0.027416130527854,0.117665134370327,-0.337947458028793,0.403050065040588,-0.232909530401230,-0.069246217608452,0.578722894191742,-0.616288781166077,0.301700174808502,0.170469015836716,-0.229976221919060,0.095139168202877,0.762468576431274,-0.112220659852028,0.252852290868759,0.494586139917374) * MODEL3_texOff(vec2(0,0));
res += mat4(0.081469081342220,0.167024418711662,-0.007003418169916,-0.145076319575310,0.120128765702248,-0.003851291956380,0.203642457723618,-0.237980872392654,0.009192240424454,-0.244096964597702,-0.004152714274824,-0.144765779376030,-0.335758626461029,0.053721431642771,0.005917552392930,-0.229375571012497) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.266715914011002,-0.051824677735567,0.025688409805298,-0.099525630474091,-0.048203155398369,-0.158464610576630,0.066712751984596,0.092747598886490,0.168802425265312,0.087291724979877,-0.235505253076553,0.232992261648178,0.080554589629173,-0.025387041270733,0.045517530292273,-0.088783174753189) * MODEL3_texOff(vec2(1,-1));
res += mat4(-0.148564890027046,0.071942843496799,0.132231444120407,-0.008291238918900,0.070962995290756,0.124767847359180,-0.022096836939454,-0.079105183482170,-0.014639900065958,0.085612475872040,-0.098186545073986,0.066670604050159,0.151626244187355,0.003920393995941,-0.031497266143560,0.355439186096191) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.030859714373946,-0.157790809869766,-0.017388330772519,0.090271644294262,0.215903028845787,-0.065659813582897,-0.097117282450199,0.006253575906157,0.282692193984985,-0.121792003512383,-0.124814160168171,-0.007093098014593,-0.333068758249283,-0.088203676044941,0.065966449677944,-0.031553912907839) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.104013085365295,-0.484575033187866,-0.506195485591888,0.509133040904999) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.074226647615433,-0.087644271552563,-0.045252677053213,0.135082781314850);
res += mat4(0.017304288223386,0.074410811066628,0.098923139274120,0.074401266872883,0.201214134693146,0.002280355431139,-0.100335262715816,0.031563084572554,-0.237396374344826,0.047642752528191,0.198601081967354,0.231797873973846,-0.040149591863155,0.092727698385715,-0.185076937079430,-0.072843745350838) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.038745351135731,0.125993087887764,0.420091599225998,0.212152823805809,0.048644114285707,0.233046367764473,-0.087761767208576,-0.164737626910210,-0.264123290777206,-0.060301523655653,0.005613569635898,0.337848514318466,-0.095556065440178,-0.077395677566528,-0.245802551507950,0.204457208514214) * MODEL1_texOff(vec2(-1,0));
res += mat4(-0.141761541366577,-0.017497250810266,-0.109827920794487,-0.018827553838491,0.107085540890694,0.116451792418957,0.043591719120741,-0.151117756962776,-0.120276376605034,-0.010607168078423,0.056317962706089,0.010605223476887,0.112590558826923,0.124116770923138,-0.082567453384399,0.021814690902829) * MODEL1_texOff(vec2(-1,1));
res += mat4(-0.045787725597620,0.279140859842300,-0.043565470725298,-0.259659409523010,-0.123785920441151,-0.340501964092255,-0.102215103805065,0.117370970547199,-0.183109417557716,0.105778224766254,0.108911439776421,0.057758223265409,0.294874608516693,0.201751679182053,0.258345484733582,0.009806700982153) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.468792140483856,0.778452098369598,-0.372882753610611,0.155760794878006,0.181832566857338,0.333272099494934,0.017885249108076,-0.094215609133244,-0.515017092227936,0.047604154795408,0.467182487249374,0.278775155544281,-0.003046573605388,-0.203875631093979,0.167413756251335,0.018462069332600) * MODEL1_texOff(vec2(0,0));
res += mat4(0.108152687549591,0.004529458936304,-0.002391899237409,-0.025843763723969,0.207446858286858,0.087509155273438,-0.064338549971581,-0.267087459564209,-0.193209916353226,-0.055584151297808,0.289994537830353,0.256278723478317,-0.177527427673340,0.067503482103348,-0.121231451630592,-0.004024790134281) * MODEL1_texOff(vec2(0,1));
res += mat4(-0.127249792218208,-0.094285950064659,-0.085379213094711,0.035230208188295,-0.112422011792660,0.178561478853226,-0.292324930429459,-0.181398853659630,0.014555407688022,0.078437447547913,-0.007396507542580,0.189532071352005,0.034279376268387,-0.005978523753583,-0.127013429999352,0.182848960161209) * MODEL1_texOff(vec2(1,-1));
res += mat4(-0.086138337850571,-0.066731877624989,-0.139773353934288,0.280169963836670,0.156539067625999,0.368303984403610,0.051498793065548,0.018093492835760,-0.229836940765381,0.033481247723103,-0.004982489626855,-0.009523469954729,-0.062459938228130,-0.031735256314278,0.004825143143535,-0.189722776412964) * MODEL1_texOff(vec2(1,0));
res += mat4(0.063542529940605,-0.077681183815002,-0.039946433156729,0.110421329736710,0.141175314784050,0.068591505289078,0.005484099034220,-0.117247797548771,-0.315397381782532,-0.007021818775684,0.111827999353409,0.076316617429256,-0.057520356029272,-0.078320145606995,-0.052824553102255,-0.065365716814995) * MODEL1_texOff(vec2(1,1));
res += mat4(-0.058381643146276,-0.302160173654556,-0.043331373482943,0.059851255267859,0.119270890951157,-0.012603649869561,-0.104658313095570,-0.200954124331474,0.042434170842171,-0.190216898918152,0.018289217725396,-0.152377322316170,0.062745727598667,0.055874954909086,-0.020909409970045,0.084435686469078) * MODEL2_texOff(vec2(-1,-1));
res += mat4(-0.089436404407024,-0.224974066019058,-0.023546567186713,0.040819585323334,0.049604400992393,-0.186617478728294,-0.169809281826019,-0.166111901402473,-0.058564394712448,-0.223712384700775,-0.321802943944931,-0.042052730917931,0.122327148914337,0.260352164506912,0.164976492524147,-0.207422241568565) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.095616482198238,-0.164272353053093,-0.062513381242752,-0.047173582017422,0.128508105874062,-0.088884182274342,-0.222061201930046,-0.040216878056526,0.192939475178719,-0.231189504265785,0.300484865903854,-0.025812786072493,-0.027609240263700,-0.275349885225296,0.000275095953839,0.400422751903534) * MODEL2_texOff(vec2(-1,1));
res += mat4(0.034775976091623,-0.322344332933426,-0.134229987859726,0.183164313435555,0.057306144386530,-0.002317653503269,-0.018361242488027,-0.073258548974991,0.152578353881836,0.027860229834914,0.145835325121880,0.024622179567814,-0.092909649014473,0.039123132824898,-0.138919308781624,0.017234805971384) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.326229989528656,-0.559986770153046,-0.477903485298157,-0.082373358309269,0.113928057253361,0.047020599246025,0.370288938283920,-0.176446989178658,-0.002375351730734,-0.108533993363380,-0.161780342459679,-0.080260626971722,0.124670736491680,0.355545848608017,0.225060313940048,-0.060647428035736) * MODEL2_texOff(vec2(0,0));
res += mat4(-0.105314016342163,-0.262753218412399,-0.033701229840517,-0.273783355951309,0.124417148530483,-0.058222088962793,-0.167925298213959,0.187025710940361,-0.372966587543488,-0.077350199222565,-0.312112182378769,0.229307100176811,0.358387023210526,-0.730437278747559,-0.526928782463074,-0.444431900978088) * MODEL2_texOff(vec2(0,1));
res += mat4(0.064506143331528,-0.027584139257669,0.057837687432766,0.181863814592361,-0.052950784564018,-0.026899928227067,0.304611444473267,-0.273166239261627,0.041877564042807,-0.070204965770245,0.008046263828874,-0.163913398981094,0.086067453026772,0.055322170257568,0.091547966003418,-0.002816004911438) * MODEL2_texOff(vec2(1,-1));
res += mat4(0.100049570202827,0.078983552753925,0.012576686218381,0.181905910372734,0.271429806947708,0.216260433197021,0.176113560795784,0.080540776252747,0.024262843653560,-0.084746688604355,-0.105264797806740,-0.268981099128723,-0.060362521559000,0.132948219776154,0.016783280298114,-0.007928715087473) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.141069248318672,0.052574560046196,0.108723193407059,0.084367439150810,0.285850763320923,0.001641021110117,-0.165515795350075,-0.082923546433449,-0.307426482439041,-0.089576549828053,-0.191574752330780,0.051260270178318,0.294291168451309,0.412093073129654,0.167860329151154,0.145600706338882) * MODEL2_texOff(vec2(1,1));
res += mat4(-0.104968339204788,0.057857647538185,-0.037689276039600,0.108263976871967,-0.050531763583422,-0.097380138933659,-0.145093753933907,-0.021105693653226,0.044566873461008,0.157336309552193,0.087023429572582,0.130718559026718,0.102418489754200,0.046421714127064,0.154644012451172,0.009639474563301) * MODEL3_texOff(vec2(-1,-1));
res += mat4(0.011993190273643,0.019707513973117,0.009255423210561,0.014410295523703,-0.300655663013458,0.221591681241989,-0.811205446720123,0.064434610307217,0.120441690087318,0.174170672893524,-0.276120901107788,0.223191291093826,-0.098051667213440,0.183948293328285,-0.874043047428131,-0.280990660190582) * MODEL3_texOff(vec2(-1,0));
res += mat4(-0.069640956819057,-0.026761185377836,-0.137201309204102,-0.122260943055153,0.212505593895912,-0.056705135852098,-0.168809428811073,-0.026847932487726,0.128472402691841,0.195904180407524,-0.014648322947323,0.129021197557449,-0.125174030661583,-0.056867159903049,-0.031692918390036,0.121229730546474) * MODEL3_texOff(vec2(-1,1));
res += mat4(-0.151416197419167,-0.122442290186882,-0.007697166875005,0.212275609374046,0.169161960482597,0.023090224713087,-0.203663721680641,0.111815236508846,0.022842796519399,-0.014807474799454,-0.123847484588623,0.131341755390167,0.227571412920952,-0.134740605950356,0.148136734962463,-0.225891515612602) * MODEL3_texOff(vec2(0,-1));
res += mat4(-0.144953399896622,-0.235991552472115,-0.032534267753363,-0.099073044955730,-0.420358777046204,-0.189659744501114,0.019568044692278,-0.036416873335838,0.060586445033550,-0.933637976646423,-0.270154595375061,0.412683010101318,-0.127810016274452,0.056069809943438,0.089445091784000,0.273669064044952) * MODEL3_texOff(vec2(0,0));
res += mat4(-0.022472260519862,0.097841247916222,0.078444227576256,-0.428789347410202,-0.007597821298987,-0.020715719088912,0.132522761821747,-0.260656058788300,-0.030075522139668,0.070782281458378,0.056011494249105,0.218465596437454,-0.058441959321499,0.091508351266384,-0.020786954089999,0.091152779757977) * MODEL3_texOff(vec2(0,1));
res += mat4(0.023291705176234,0.030744751915336,0.047218609601259,0.058642290532589,0.223589852452278,0.013168748468161,0.106513962149620,0.090145476162434,-0.061067383736372,0.024910971522331,-0.116183467209339,0.205711662769318,-0.101511470973492,-0.047384113073349,-0.012647667899728,-0.205668926239014) * MODEL3_texOff(vec2(1,-1));
res += mat4(0.043531656265259,0.195819154381752,0.100100614130497,-0.280760318040848,0.047963738441467,0.031831491738558,0.026447031646967,-0.018598189577460,-0.171252414584160,-0.026852378621697,0.078574351966381,-0.049302268773317,0.057069912552834,-0.093118645250797,0.216956064105034,-0.026568751782179) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.187498629093170,-0.015906907618046,0.108008161187172,-0.220102429389954,-0.081072486937046,-0.009374648332596,-0.017132593318820,-0.051330115646124,0.033325716853142,-0.078537233173847,-0.079871878027916,0.206991970539093,-0.027472857385874,0.040377680212259,-0.053334645926952,-0.008693774230778) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-1.043681740760803,-0.576830983161926,0.217685133218765,0.597685754299164) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL4
//!BIND MODEL5
//!BIND MODEL6
//!SAVE MODEL1
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 3_1

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.127505376935005,0.028479008004069,-0.091149240732193,-0.197285801172256);
res += mat4(0.288733005523682,0.232363328337669,-0.075267687439919,-0.076781310141087,-0.044053163379431,0.129252478480339,0.035477042198181,0.028203591704369,0.048555288463831,-0.048057351261377,-0.004944384098053,-0.064102239906788,0.104168951511383,0.064189076423645,0.033875778317451,0.172016978263855) * MODEL4_texOff(vec2(-1,-1));
res += mat4(0.299224644899368,0.221599057316780,-0.012262970209122,-0.031499303877354,0.126921430230141,-0.506620168685913,0.124761499464512,0.051792867481709,-0.157379209995270,-0.134654805064201,-0.178355053067207,-0.206013083457947,-0.048426244407892,-0.054574511945248,0.013943097554147,0.149600356817245) * MODEL4_texOff(vec2(-1,0));
res += mat4(0.148695275187492,0.250504195690155,0.171283438801765,0.006748583167791,0.185852572321892,-0.275628209114075,-0.187961205840111,-0.061698701232672,0.025157162919641,-0.173066183924675,-0.086903415620327,-0.085391767323017,-0.125040277838707,-0.022706545889378,-0.105038225650787,0.053360827267170) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.122444324195385,0.106250561773777,-0.065699525177479,0.059576176106930,-0.274765133857727,0.287997663021088,-0.272981971502304,0.049367159605026,0.049775619059801,0.134131282567978,-0.297551840543747,-0.130153283476830,0.005842319689691,0.038031350821257,0.325987726449966,0.062253262847662) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.215006232261658,0.356677621603012,-0.156604126095772,0.051242660731077,-0.105514213442802,-0.501636624336243,0.433807194232941,-0.056216213852167,0.494810193777084,-0.117434687912464,0.272923886775970,0.264571636915207,-0.677615582942963,-0.106125429272652,0.238250046968460,0.003801224986091) * MODEL4_texOff(vec2(0,0));
res += mat4(0.312871366739273,0.310640752315521,0.068489514291286,-0.004281684290618,0.325662314891815,-0.247251689434052,-0.361840426921844,0.389138132333755,-0.192118898034096,-0.075258858501911,-0.085040196776390,0.039929259568453,-0.058376070111990,0.116486668586731,-0.749022185802460,-0.276114016771317) * MODEL4_texOff(vec2(0,1));
res += mat4(0.247283488512039,0.058763034641743,-0.064132831990719,-0.050580501556396,0.176786944270134,-0.057169035077095,0.008106080815196,0.021180169656873,0.140501528978348,-0.156238526105881,0.021744821220636,0.259995341300964,-0.050710503011942,-0.071965627372265,0.044624261558056,-0.104933813214302) * MODEL4_texOff(vec2(1,-1));
res += mat4(0.271616637706757,0.207297220826149,-0.159988477826118,0.013582534156740,-0.161902785301208,0.089929826557636,0.093052156269550,-0.180543467402458,0.240180999040604,-0.336609929800034,-0.352344751358032,0.140480399131775,0.238614991307259,-0.078884415328503,-0.104310274124146,0.195684403181076) * MODEL4_texOff(vec2(1,0));
res += mat4(0.371815234422684,0.221811115741730,0.152085691690445,-0.093897268176079,0.060741163790226,-0.006812758278102,-0.101990886032581,-0.157011717557907,0.023238092660904,0.076850272715092,0.310180574655533,0.091999463737011,-0.028709216043353,0.021718917414546,0.063580550253391,-0.089749164879322) * MODEL4_texOff(vec2(1,1));
res += mat4(0.062632158398628,0.040289577096701,0.103421986103058,0.015419360250235,0.090121239423752,0.137966498732567,0.004003129899502,0.056411199271679,0.018335033208132,0.047646544873714,-0.155061453580856,-0.177669703960419,-0.353637307882309,-0.208666265010834,-0.140298619866371,-0.007505489513278) * MODEL5_texOff(vec2(-1,-1));
res += mat4(0.105599492788315,-0.142197951674461,-0.017077105119824,0.298689693212509,-0.252655535936356,0.281300634145737,0.204770386219025,0.415208995342255,-0.139205142855644,0.027096739038825,0.056136749684811,-0.267663657665253,-0.045108389109373,-0.361249357461929,-0.052835561335087,-0.076183781027794) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.006626600865275,0.167655080556870,-0.014681526459754,0.072172224521637,0.093095257878304,-0.030487323179841,-0.179214388132095,0.078800074756145,0.047995042055845,0.074310801923275,0.033780794590712,0.035667788237333,-0.234373167157173,-0.068258658051491,-0.039518773555756,-0.005649630911648) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.025384543463588,0.034544054418802,-0.075646921992302,-0.072140999138355,0.298073112964630,-0.224245488643646,0.559616327285767,0.101295731961727,0.426503896713257,0.172262057662010,-0.165621832013130,-0.248462393879890,-0.465670883655548,-0.107672818005085,-0.166229978203773,-0.137052267789841) * MODEL5_texOff(vec2(0,-1));
res += mat4(-0.314307391643524,-0.614973723888397,0.094841673970222,-0.690876483917236,0.430649012327194,0.252514958381653,-0.499446362257004,-0.247370526194572,0.414598256349564,0.204110294580460,0.495252817869186,0.192404106259346,-0.209590032696724,-0.265809774398804,0.229814708232880,-0.063207611441612) * MODEL5_texOff(vec2(0,0));
res += mat4(0.088889755308628,-0.021531743928790,-0.136307254433632,-0.225904136896133,-0.245146498084068,0.328297495841980,0.138492852449417,0.157407417893410,-0.030026931315660,0.209299296140671,0.002080122241750,0.077061526477337,-0.311867862939835,-0.133101254701614,-0.158877015113831,0.081233926117420) * MODEL5_texOff(vec2(0,1));
res += mat4(-0.103462852537632,-0.089951753616333,0.093255944550037,-0.019733993336558,-0.017227303236723,0.060894414782524,0.196921184659004,0.040480811148882,-0.228324398398399,-0.071624279022217,-0.058175902813673,-0.068407244980335,-0.289516657590866,-0.263302057981491,-0.184694245457649,0.025194618850946) * MODEL5_texOff(vec2(1,-1));
res += mat4(0.033410523086786,0.061307422816753,0.167721644043922,0.269932031631470,0.066199421882629,-0.315576076507568,0.032797146588564,0.446245729923248,0.002499915892258,-0.047285567969084,0.083561509847641,-0.169677883386612,-0.077036671340466,-0.189057394862175,0.110113501548767,-0.003535134019330) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.034257594496012,-0.043596334755421,-0.388574957847595,-0.071928620338440,0.155532091856003,0.067725867033005,0.045327328145504,0.041318636387587,0.025971591472626,0.137337625026703,0.063491240143776,0.021599758416414,-0.333421319723129,-0.270240873098373,0.141270637512207,-0.019481351599097) * MODEL5_texOff(vec2(1,1));
res += mat4(-0.003198085119948,-0.031037064269185,-0.080226227641106,-0.008477413095534,-0.119757778942585,0.056150853633881,-0.047653589397669,-0.069752648472786,-0.075086377561092,-0.046887341886759,0.020883729681373,-0.032501634210348,-0.033246587961912,0.101737141609192,-0.015215693973005,0.031453907489777) * MODEL6_texOff(vec2(-1,-1));
res += mat4(-0.076353728771210,0.622277379035950,0.127519428730011,0.429204225540161,-0.182848110795021,-0.074170842766762,0.055082947015762,-0.118576407432556,0.213350921869278,0.007030122913420,-0.005119169130921,-0.091480307281017,-0.087298333644867,0.255914747714996,0.210071682929993,0.357227325439453) * MODEL6_texOff(vec2(-1,0));
res += mat4(-0.156093761324883,0.002799022244290,-0.346487641334534,0.081331931054592,-0.250259816646576,-0.255239278078079,0.066208332777023,-0.044881541281939,-0.026317890733480,0.174904361367226,0.019806738942862,0.018699461594224,-0.000246095325565,0.129339471459389,0.254106402397156,0.181914821267128) * MODEL6_texOff(vec2(-1,1));
res += mat4(0.568523526191711,-0.146557018160820,0.396030306816101,0.253538310527802,0.219356462359428,0.156607285141945,0.000560533371754,0.136375904083252,-0.100563712418079,-0.186566814780235,0.134586825966835,-0.064387276768684,0.149500414729118,-0.077272176742554,0.042917817831039,0.020998746156693) * MODEL6_texOff(vec2(0,-1));
res += mat4(-0.441339015960693,-0.181167423725128,-0.141706183552742,-0.198390275239944,0.219408735632896,0.199139907956123,0.096919782459736,0.049161069095135,-0.064145162701607,0.578813195228577,-0.382408350706100,0.257451087236404,-0.486128121614456,-0.145876511931419,-0.089782677590847,-1.040876269340515) * MODEL6_texOff(vec2(0,0));
res += mat4(-0.291768401861191,-0.340990275144577,-0.738973855972290,-0.228286117315292,-0.219560861587524,-0.296148419380188,0.116516917943954,0.107351288199425,0.128402367234230,-0.171947687864304,0.103599660098553,0.136769667267799,-0.097380176186562,0.635730862617493,0.158835500478745,-0.190102458000183) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.079740598797798,0.161439895629883,0.293572098016739,-0.077566184103489,-0.040476016700268,0.153118580579758,0.033827751874924,0.283101886510849,-0.145570680499077,0.138609156012535,-0.175574541091919,0.108424872159958,-0.080630183219910,-0.002031473675743,-0.010658186860383,0.127466723322868) * MODEL6_texOff(vec2(1,-1));
res += mat4(0.176578566431999,-0.043631758540869,-0.191092625260353,-0.148832008242607,0.200086608529091,0.222378224134445,-0.021284060552716,0.287910997867584,0.207040533423424,0.437768042087555,0.145169124007225,0.351354420185089,0.254104226827621,-0.004790810402483,-0.003426410723478,0.394175916910172) * MODEL6_texOff(vec2(1,0));
res += mat4(0.019905930384994,-0.106719866394997,-0.281552582979202,0.005573362577707,0.063511706888676,-0.094222776591778,0.330923259258270,0.126411408185959,0.041934814304113,0.040547769516706,-0.105677478015423,0.083202064037323,0.030303286388516,0.140825390815735,0.420887380838394,0.175121545791626) * MODEL6_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.039713017642498,0.169002160429955,0.162069514393806,0.261144965887070) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(0.001633255509660,0.054471552371979,0.053101632744074,-0.117425277829170);
res += mat4(-0.380616068840027,-0.092972241342068,0.198455169796944,-0.258476108312607,-0.095261342823505,0.091360196471214,-0.137199208140373,0.148000419139862,-0.015769502148032,0.027247112244368,0.256470590829849,0.175581425428391,0.004273050464690,0.013281233608723,0.022550655528903,0.074147775769234) * MODEL4_texOff(vec2(-1,-1));
res += mat4(-0.349334180355072,-0.138666063547134,-0.452739208936691,-0.415522009134293,0.485019296407700,0.047183744609356,0.012052576057613,-0.093769781291485,-0.156071454286575,-0.311265915632248,0.015446576289833,0.143935456871986,0.148141562938690,0.077465154230595,-0.294159859418869,-0.401162922382355) * MODEL4_texOff(vec2(-1,0));
res += mat4(-0.131537765264511,0.020437544211745,-0.143451318144798,0.076677411794662,0.015208199620247,0.010439527221024,-0.116387508809566,0.079999729990959,-0.149618402123451,0.201158270239830,0.025374343618751,-0.034634381532669,-0.071890152990818,0.019102411344647,-0.191512465476990,-0.001785591477528) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.018979132175446,0.155409067869186,0.020613385364413,0.295749992132187,0.358928471803665,-0.081281147897243,0.020656632259488,0.282534599304199,0.184999182820320,0.137625768780708,-0.000038646150642,-0.118341937661171,-0.264294505119324,-0.661953687667847,0.046320129185915,-0.082939401268959) * MODEL4_texOff(vec2(0,-1));
res += mat4(-0.085698671638966,-0.023507948964834,-0.038990352302790,0.281386852264404,0.112866729497910,-0.126596346497536,0.143904894590378,0.623616099357605,-0.274279057979584,-0.018623445183039,-0.251549035310745,0.246171504259109,-0.120385043323040,-0.036549489945173,-0.001281638513319,0.474002361297607) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.018776411190629,0.038547787815332,-0.115309119224548,0.015783436596394,-0.071933537721634,0.002650261856616,-0.194875523447990,0.241110518574715,0.002931056078523,-0.070709906518459,-0.011888884007931,0.286207467317581,-0.169041708111763,-0.041517060250044,-0.587491512298584,-0.004513448569924) * MODEL4_texOff(vec2(0,1));
res += mat4(0.018825925886631,0.328993678092957,-0.071961320936680,-0.298931539058685,0.544905781745911,-0.025746854022145,-0.073167815804482,-0.024286519736052,-0.092623323202133,0.204842224717140,-0.040420901030302,-0.172381520271301,0.079745151102543,-0.462662070989609,0.059365849941969,0.294279932975769) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.037435319274664,0.187808230519295,0.112299613654613,-0.259020656347275,0.028827631846070,0.030532788485289,-0.036761231720448,-0.221907407045364,0.118993476033211,0.080957390367985,0.239566475152969,-0.247005820274353,0.294754743576050,0.098549954593182,-0.333976626396179,0.285711705684662) * MODEL4_texOff(vec2(1,0));
res += mat4(0.015635089948773,0.018844325095415,-0.006501982919872,-0.072840787470341,0.080749467015266,-0.055689562112093,-0.184155493974686,-0.105195268988609,0.076199956238270,-0.117085494101048,0.015193727798760,-0.232618868350983,0.056966435164213,-0.097838506102562,-0.221768587827682,0.056401293724775) * MODEL4_texOff(vec2(1,1));
res += mat4(0.065443158149719,0.025336034595966,0.032885648310184,0.016221711412072,0.141985923051834,0.012296373024583,0.033846892416477,-0.041648428887129,0.166624337434769,0.038507774472237,-0.048017755150795,0.059809613972902,0.050252839922905,0.177008539438248,-0.114270426332951,-0.213346838951111) * MODEL5_texOff(vec2(-1,-1));
res += mat4(-0.105712175369263,0.125857278704643,0.095212817192078,0.168214991688728,0.122948989272118,-0.042840309441090,-0.233930826187134,0.259311854839325,0.128812909126282,-0.291189491748810,-0.020891722291708,0.189781218767166,0.236291885375977,0.364709764719009,-0.035673439502716,-0.204382687807083) * MODEL5_texOff(vec2(-1,0));
res += mat4(0.183822691440582,-0.040326893329620,0.061848226934671,0.088140547275543,-0.041987072676420,0.019699184224010,0.057995934039354,-0.006014665123075,0.123689889907837,0.024947546422482,-0.052862297743559,0.145198553800583,-0.262191325426102,0.088602893054485,0.051112018525600,-0.143748596310616) * MODEL5_texOff(vec2(-1,1));
res += mat4(0.169526413083076,0.207289710640907,0.084289297461510,0.055315569043159,0.061729490756989,0.131272494792938,-0.327427864074707,-0.027374994009733,0.128776893019676,0.065795697271824,-0.251344084739685,-0.060556158423424,0.192630827426910,0.051543664187193,0.079733863472939,0.122528612613678) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.475638628005981,-0.388308346271515,0.154419258236885,0.794076561927795,0.064929261803627,-0.120415389537811,-0.328283876180649,-0.040689069777727,0.175155088305473,0.143176063895226,-0.230349600315094,-0.649626672267914,-0.121321894228458,-0.534170627593994,0.072692431509495,-0.057597152888775) * MODEL5_texOff(vec2(0,0));
res += mat4(0.226678371429443,0.024717779830098,0.154308855533600,0.261220544576645,-0.018431087955832,0.147686600685120,-0.101099185645580,-0.045805096626282,-0.275226742029190,-0.056975498795509,0.008995539508760,-0.345857739448547,-0.231018647551537,0.066987544298172,-0.250368297100067,0.077271118760109) * MODEL5_texOff(vec2(0,1));
res += mat4(0.007119409274310,0.061759289354086,0.215120941400528,-0.085867457091808,-0.179953083395958,0.206153959035873,-0.160556256771088,0.023398054763675,0.149791151285172,0.354986608028412,-0.207521960139275,-0.075126551091671,0.077849820256233,0.301973581314087,0.003938710782677,0.018517958000302) * MODEL5_texOff(vec2(1,-1));
res += mat4(-0.023531174287200,0.114637039601803,0.156108945608139,-0.303394556045532,-0.174146518111229,0.002696040784940,-0.097164668142796,-0.062716439366341,-0.014922308735549,-0.254524022340775,0.230569899082184,-0.207093268632889,0.553859591484070,0.259863346815109,0.158282548189163,-0.347347021102905) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.059900745749474,-0.096088372170925,-0.020462686195970,-0.118804588913918,0.046887628734112,0.028973108157516,-0.137429475784302,0.025790512561798,-0.038134071975946,-0.049134641885757,-0.269741386175156,0.027033599093556,0.065365307033062,0.088707417249680,-0.031034342944622,-0.112930633127689) * MODEL5_texOff(vec2(1,1));
res += mat4(-0.203709527850151,-0.031175062060356,0.073519900441170,0.026591602712870,0.100151404738426,0.113397076725960,-0.063180908560753,0.106809668242931,0.154836013913155,0.005013327579945,-0.062182135879993,0.155120760202408,-0.222136795520782,-0.041094470769167,0.119214542210102,-0.114851966500282) * MODEL6_texOff(vec2(-1,-1));
res += mat4(-0.089222893118858,-0.102784447371960,0.243074759840965,0.021884448826313,0.029658315703273,0.099220342934132,-0.188892588019371,-0.216712057590485,0.122896552085876,-0.150853589177132,-0.342574357986450,0.385011643171310,-0.073341012001038,0.239822462201118,0.188256502151489,-0.193555548787117) * MODEL6_texOff(vec2(-1,0));
res += mat4(0.052714381366968,-0.056968703866005,0.107298299670219,-0.028682688251138,0.052574139088392,-0.022604042664170,0.109461411833763,0.044109940528870,0.036355800926685,0.003803724423051,0.015070481225848,0.310366988182068,0.067195639014244,-0.019751656800508,-0.061836302280426,-0.137436449527740) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.389439344406128,-0.512985944747925,0.059378959238529,-0.289942175149918,0.126470059156418,0.036092288792133,-0.124632902443409,-0.088003091514111,-0.025580389425159,0.183192193508148,0.051003076136112,0.120419882237911,-0.139544308185577,-0.071583658456802,0.200932577252388,0.003272449597716) * MODEL6_texOff(vec2(0,-1));
res += mat4(-0.266219615936279,0.474357753992081,-0.219215869903564,-0.005055150948465,0.511944830417633,-0.375247269868851,0.252001315355301,-0.261297494173050,-0.309343099594116,-0.296677470207214,0.124971158802509,-0.021791016682982,0.001209647394717,-0.001429510302842,0.273188352584839,-0.239941895008087) * MODEL6_texOff(vec2(0,0));
res += mat4(-0.063318081200123,-0.209215328097343,0.191284462809563,0.084689475595951,-0.057877827435732,0.036531303077936,-0.058096375316381,-0.039198059588671,-0.392889291048050,0.057631462812424,-0.002964318031445,0.271917283535004,-0.032877996563911,0.037465024739504,-0.050669275224209,0.083300434052944) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.331932693719864,-0.066447056829929,0.109160766005516,0.127774029970169,0.040368042886257,-0.194845899939537,-0.032593972980976,0.072344645857811,0.054135892540216,0.009820970706642,-0.165581747889519,-0.095771282911301,0.187668859958649,-0.260644376277924,-0.003376970998943,-0.043423987925053) * MODEL6_texOff(vec2(1,-1));
res += mat4(0.100958578288555,0.070116005837917,0.174564048647881,-0.020193910226226,0.224163949489594,-0.115104183554649,0.046088907867670,0.321297347545624,-0.483756452798843,0.029969349503517,-0.244517996907234,0.083847843110561,-0.166984096169472,-0.147338494658470,0.011389228515327,0.215924918651581) * MODEL6_texOff(vec2(1,0));
res += mat4(0.008906111121178,-0.090148650109768,0.140800669789314,-0.004651540424675,0.009172777645290,-0.056325174868107,0.134963139891624,-0.005512455478311,-0.004825728479773,-0.095807150006294,0.007749964017421,-0.111293129622936,-0.091903492808342,0.010581231676042,0.032332815229893,0.108355805277824) * MODEL6_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.515390753746033,0.786955893039703,0.842041134834290,-0.047555297613144) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL4
//!BIND MODEL5
//!BIND MODEL6
//!SAVE MODEL2
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 3_2

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.245294913649559,-0.101685196161270,0.138370662927628,0.219192966818810);
res += mat4(0.051328610628843,0.017826337367296,-0.143621221184731,0.030491566285491,-0.001966373529285,-0.225336953997612,-0.202580869197845,0.017192374914885,-0.138209939002991,0.045026127249002,0.059375025331974,0.102928526699543,-0.160518437623978,-0.023186091333628,0.129045635461807,-0.011376374401152) * MODEL4_texOff(vec2(-1,-1));
res += mat4(-0.027602611109614,0.193120971322060,-0.025369865819812,0.134154200553894,0.307871133089066,-0.259073197841644,-0.114951118826866,0.287461936473846,-0.101162478327751,-0.178561866283417,-0.000400794378947,-0.056218884885311,-0.043598506599665,-0.973167419433594,-0.022437566891313,-0.018961582332850) * MODEL4_texOff(vec2(-1,0));
res += mat4(-0.109386160969734,0.198887377977371,-0.139538884162903,-0.054465144872665,0.128882601857185,-0.026180896908045,-0.091706074774265,-0.127490401268005,0.082013249397278,-0.012136067263782,0.053076837211847,0.057012319564819,0.128802731633186,-0.254306018352509,0.058201786130667,0.050106532871723) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.139551863074303,-0.158178538084030,-0.138274997472763,-0.081695817410946,-0.115673273801804,0.131419911980629,0.082227401435375,0.032157436013222,0.346994072198868,-0.225339472293854,0.302281886339188,-0.169596046209335,-0.792228102684021,0.025663364678621,-0.069401457905769,-0.067010268568993) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.029410351067781,-0.124125674366951,-0.076505839824677,0.013980268500745,0.188030019402504,0.331409126520157,-0.626682400703430,-0.208679869771004,-0.509857594966888,-0.206978440284729,0.011987399309874,-0.248803406953812,0.312196761369705,0.384282857179642,-0.410695821046829,0.135052993893623) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.113726258277893,-0.075348064303398,-0.100499942898750,0.054586008191109,-0.039672710001469,0.018243342638016,-0.295765846967697,0.094632051885128,0.180520892143250,0.004552566912025,0.259254753589630,-0.049074895679951,0.403226733207703,0.084448456764221,-0.404080033302307,0.071452818810940) * MODEL4_texOff(vec2(0,1));
res += mat4(0.170326545834541,-0.147408738732338,-0.085431255400181,-0.059933852404356,0.021834237501025,0.067253723740578,0.113206595182419,0.039156280457973,-0.222085073590279,0.040478549897671,-0.007248169276863,-0.114161103963852,-0.186686381697655,0.049817129969597,0.030241340398788,-0.030994452536106) * MODEL4_texOff(vec2(1,-1));
res += mat4(0.113889709115028,-0.104870833456516,0.046189393848181,-0.019146062433720,0.087642036378384,0.041514735668898,-0.263771206140518,0.240845993161201,-0.009462643414736,0.239910766482353,0.442814916372299,-0.385088264942169,-0.128818511962891,0.374638289213181,0.062013041228056,-0.096985906362534) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.056045819073915,-0.113608986139297,-0.151893109083176,0.069370239973068,0.020906396210194,0.106216311454773,-0.014982880093157,0.027672404423356,-0.054961748421192,0.029440104961395,0.194402575492859,-0.022301092743874,0.110976949334145,0.067180290818214,-0.071657426655293,0.030581597238779) * MODEL4_texOff(vec2(1,1));
res += mat4(-0.047264978289604,-0.277577340602875,-0.016864551231265,-0.161578163504601,0.172273963689804,0.063649870455265,0.003198785707355,-0.040881954133511,0.235165476799011,0.213298559188843,-0.121868975460529,0.109908565878868,0.015253466553986,0.102360874414444,0.043192509561777,0.119542710483074) * MODEL5_texOff(vec2(-1,-1));
res += mat4(-0.033757168799639,-0.301801532506943,0.217049449682236,-0.303624331951141,0.063147641718388,0.443398624658585,-0.290065318346024,-0.058467116206884,-0.157335117459297,0.204512953758240,0.014342294074595,0.167783662676811,-0.096724122762680,-0.214949861168861,0.122103236615658,0.027274379506707) * MODEL5_texOff(vec2(-1,0));
res += mat4(0.079981096088886,-0.084220767021179,0.186128303408623,-0.085676744580269,0.039795745164156,0.035251244902611,-0.008216970600188,-0.069731563329697,-0.182716920971870,0.049872849136591,-0.047740817070007,-0.043456286191940,0.040625415742397,-0.141770854592323,0.172948062419891,-0.020332233980298) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.034710105508566,0.165411815047264,0.139767080545425,0.150298029184341,0.714727461338043,0.037133470177650,-0.082431972026825,-0.407734245061874,0.529061198234558,-0.222029149532318,-0.190343186259270,-0.309954106807709,0.036689545959234,-0.001089369761758,0.107217729091644,0.077388808131218) * MODEL5_texOff(vec2(0,-1));
res += mat4(-0.056757673621178,0.341581523418427,-0.633279442787170,0.329542636871338,-0.242961674928665,-0.316850125789642,-0.464822143316269,-0.239836558699608,-0.580245316028595,-0.129742652177811,0.272174537181854,-0.005477914121002,-0.073393076658249,-0.012728186324239,0.029422875493765,0.049336008727551) * MODEL5_texOff(vec2(0,0));
res += mat4(0.118339419364929,-0.010091992095113,-0.020784353837371,-0.020777013152838,0.269053876399994,0.010163509286940,0.392155855894089,-0.248938083648682,-0.059291724115610,0.014214971102774,-0.027156623080373,-0.068465948104858,0.158276930451393,0.038677003234625,-0.042048614472151,-0.086468935012817) * MODEL5_texOff(vec2(0,1));
res += mat4(-0.119049780070782,0.059725526720285,-0.075645677745342,0.058204408735037,0.101203188300133,0.032398883253336,0.131099969148636,-0.068314351141453,0.342598587274551,-0.087611585855484,0.084874540567398,-0.019309304654598,0.062631726264954,-0.023198511451483,0.073900461196899,-0.011799811385572) * MODEL5_texOff(vec2(1,-1));
res += mat4(-0.142678022384644,-0.134476393461227,-0.153853356838226,0.182912632822990,0.014095156453550,0.039285279810429,0.136093989014626,-0.173876002430916,-0.027692848816514,-0.216746166348457,0.131602227687836,0.115477405488491,-0.015914827585220,-0.083322659134865,0.125340029597282,-0.000642082944978) * MODEL5_texOff(vec2(1,0));
res += mat4(0.064324058592319,0.022463643923402,-0.125984594225883,0.062443848699331,0.151053309440613,-0.012118727900088,0.032584086060524,-0.041754648089409,-0.075715370476246,0.025099428370595,-0.010984443128109,-0.036974836140871,-0.048306658864021,-0.194171622395515,-0.039504822343588,-0.005103312898427) * MODEL5_texOff(vec2(1,1));
res += mat4(0.011009922251105,0.044047933071852,0.068653658032417,-0.387605339288712,0.191452383995056,0.346297472715378,-0.012172701768577,0.119436882436275,-0.050795320421457,0.095296390354633,-0.099034227430820,0.001120121451095,-0.076072961091995,-0.058888677507639,0.041254028677940,-0.195587515830994) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.148364901542664,0.023570118471980,-0.237009853124619,-0.045002419501543,-0.118212029337883,0.322975963354111,-0.004062349442393,0.151948392391205,0.001960241934285,0.404620677232742,0.215423628687859,0.002927259542048,-0.002714195288718,-0.238151848316193,-0.034710481762886,-0.542457461357117) * MODEL6_texOff(vec2(-1,0));
res += mat4(-0.069757945835590,-0.030860371887684,-0.031610645353794,0.060365933924913,0.018424041569233,0.017324946820736,0.008964948356152,0.040962927043438,-0.032988838851452,0.133377239108086,0.054468650370836,0.019826352596283,0.160573661327362,0.163195133209229,0.062696889042854,-0.319572150707245) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.002271612640470,0.186655983328819,-0.042707059532404,-0.185635536909103,0.274180591106415,0.017021628096700,0.118677347898483,-0.101171612739563,0.022796053439379,0.379539191722870,-0.257534146308899,-0.022525668144226,-0.353424459695816,-0.063963808119297,-0.191242441534996,-0.045542433857918) * MODEL6_texOff(vec2(0,-1));
res += mat4(-0.029050670564175,-0.334968835115433,0.129406645894051,0.014745293185115,-0.102634467184544,0.105942480266094,0.333549588918686,-0.059875242412090,0.241321429610252,0.730289697647095,-0.309205651283264,-0.149175912141800,-0.512064993381500,-0.281627863645554,-0.267358899116516,0.736311197280884) * MODEL6_texOff(vec2(0,0));
res += mat4(0.032517038285732,-0.244406402111053,-0.347003132104874,0.311124831438065,-0.088025569915771,0.079067148268223,0.092589929699898,-0.059660319238901,-0.270913720130920,0.061100173741579,-0.046664245426655,-0.036496151238680,0.373344123363495,0.062004134058952,0.229011684656143,-0.330830186605453) * MODEL6_texOff(vec2(0,1));
res += mat4(0.098347291350365,-0.111838579177856,0.170835867524147,-0.143757328391075,0.112316079437733,-0.012129310518503,0.128233447670937,-0.185478001832962,0.141253814101219,-0.237687915563583,0.013332921080291,-0.169415831565857,0.068213410675526,0.091476775705814,0.010388056747615,-0.053675387054682) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.267782956361771,0.232639566063881,0.214114248752594,-0.340945214033127,0.048485849052668,0.036930728703737,0.281246423721313,-0.093737311661243,-0.082023657858372,-0.637433826923370,0.055104013532400,-0.068244710564613,0.107213139533997,0.295104950666428,0.085188634693623,-0.210453093051910) * MODEL6_texOff(vec2(1,0));
res += mat4(0.132315024733543,0.169466659426689,0.038036547601223,-0.051204051822424,-0.191036999225616,-0.030229110270739,0.197635322809219,-0.017411449924111,-0.070589445531368,-0.080066777765751,0.137182042002678,-0.097851358354092,0.077498093247414,-0.055996283888817,0.019970227032900,-0.104776710271835) * MODEL6_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.161507993936539,-0.130710691213608,0.461233347654343,0.602026462554932) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(-0.049438279122114,0.125205129384995,-0.002653281902894,-0.027107585221529);
res += mat4(-0.009254344739020,-0.056344076991081,0.200882032513618,0.268854916095734,-0.087898120284081,-0.015859840437770,0.225742891430855,-0.077716961503029,0.366804718971252,-0.021733229979873,-0.142015233635902,0.223505556583405,0.075757123529911,-0.034480240195990,-0.113364502787590,-0.024926254525781) * MODEL4_texOff(vec2(-1,-1));
res += mat4(-0.083449080586433,0.167141884565353,0.053369417786598,0.071132048964500,-0.100873850286007,-0.198865637183189,-0.113489903509617,-0.091960161924362,-0.260703802108765,0.131052941083908,0.026493754237890,0.084565937519073,-0.000220790127059,-0.079804599285126,-0.116388127207756,0.062615483999252) * MODEL4_texOff(vec2(-1,0));
res += mat4(-0.077730730175972,0.092387408018112,-0.112870983779430,0.178643971681595,0.011801533401012,-0.015586841851473,-0.005002933554351,0.092871479690075,-0.294722616672516,0.059470932930708,0.026603141799569,0.356924533843994,-0.140949934720993,0.048125136643648,-0.015377064235508,-0.027291089296341) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.499668657779694,0.007203903980553,0.139146000146866,0.255397349596024,0.215115666389465,-0.094058364629745,0.058385569602251,0.317175388336182,0.251174151897430,0.041929323226213,0.058834969997406,0.068723306059837,-0.406727373600006,0.049941968172789,0.365154355764389,0.334552258253098) * MODEL4_texOff(vec2(0,-1));
res += mat4(-0.461558848619461,0.335408180952072,0.066675290465355,0.100064717233181,0.340540409088135,-0.648525953292847,-0.406349629163742,-0.441967427730560,-0.257000774145126,-0.117404341697693,-0.338571757078171,-0.135142117738724,0.563921749591827,-0.348255634307861,-0.209331482648849,-0.420165866613388) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.277319163084030,-0.109255857765675,0.026889231055975,0.108462125062943,0.026691660284996,-0.019377298653126,0.083032459020615,0.183641746640205,-0.122677072882652,-0.004311258438975,0.151575937867165,-0.055971562862396,-0.043778114020824,0.182725116610527,0.028339004144073,-0.018163245171309) * MODEL4_texOff(vec2(0,1));
res += mat4(0.012900707311928,-0.101456739008427,0.022711358964443,0.025115761905909,-0.178729280829430,0.115988478064537,-0.001941465889104,0.214561462402344,0.064625315368176,-0.006438772659749,0.111223317682743,-0.124899744987488,-0.078781917691231,0.066105701029301,-0.164432197809219,0.196369245648384) * MODEL4_texOff(vec2(1,-1));
res += mat4(0.024154171347618,-0.001540993805975,-0.000618308666162,0.024274893105030,-0.038120053708553,-0.273565530776978,0.116596288979053,0.026170738041401,-0.054643951356411,-0.029647771269083,0.161774441599846,-0.118604347109795,-0.048818990588188,-0.010148769244552,0.079861737787724,0.355639994144440) * MODEL4_texOff(vec2(1,0));
res += mat4(0.028158076107502,0.050172675400972,0.069202892482281,-0.025042314082384,0.149933487176895,-0.126734122633934,-0.108582101762295,-0.145722389221191,-0.013178120367229,0.050263702869415,0.254001677036285,-0.043588232249022,-0.109969891607761,0.130583494901657,-0.028747731819749,0.026509273797274) * MODEL4_texOff(vec2(1,1));
res += mat4(-0.065075233578682,0.062103904783726,0.027809510007501,0.007530064787716,0.027479277923703,-0.043085388839245,-0.150906533002853,0.016445204615593,0.013094165362418,-0.089647851884365,-0.181559726595879,0.051064867526293,0.115329459309578,0.030289152637124,0.236864015460014,-0.042668417096138) * MODEL5_texOff(vec2(-1,-1));
res += mat4(-0.052085019648075,0.064318612217903,0.133207574486732,-0.088420219719410,0.323487281799316,-0.091913752257824,-0.014477242715657,-0.124026775360107,0.074210092425346,-0.041644860059023,-0.097111441195011,0.127952978014946,-0.109072484076023,0.044185154139996,0.220904842019081,0.108779199421406) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.205091580748558,-0.062836922705173,-0.189669772982597,-0.067946001887321,0.048661373555660,0.005088282283396,-0.014269444160163,0.052641995251179,0.023301441222429,0.025949565693736,0.005340760108083,0.241721957921982,-0.243937909603119,-0.029336987063289,0.282371014356613,0.056763920933008) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.115297764539719,0.098776243627071,-0.304603308439255,0.005345588084310,-0.260762214660645,-0.022553436458111,-0.135123863816261,-0.204189866781235,-0.123664222657681,-0.200776785612106,-0.152883738279343,-0.127606630325317,0.313110709190369,-0.082933247089386,-0.218364104628563,0.177387103438377) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.103280879557133,-0.092725880444050,-0.228146776556969,-0.130563318729401,0.394993573427200,-1.257430911064148,-0.133374467492104,-0.229593008756638,0.156372800469398,-0.215697407722473,-0.061316885054111,-0.259021073579788,-0.098508976399899,0.236669450998306,0.192981913685799,-0.037396896630526) * MODEL5_texOff(vec2(0,0));
res += mat4(-0.099556691944599,0.032457936555147,-0.172710403800011,0.038529571145773,0.330946564674377,-0.103689044713974,-0.104808390140533,0.101419582962990,0.275282561779022,-0.215219020843506,0.130995377898216,-0.121233887970448,-0.407689124345779,0.133735164999962,0.286238431930542,0.328493922948837) * MODEL5_texOff(vec2(0,1));
res += mat4(-0.075592197477818,0.098785720765591,-0.079303845763206,0.115611769258976,-0.146888345479965,-0.328659504652023,0.126682698726654,-0.193138331174850,-0.008655129000545,-0.320067256689072,-0.201510459184647,-0.194352477788925,0.230617925524712,-0.225543186068535,0.071429058909416,-0.158839017152786) * MODEL5_texOff(vec2(1,-1));
res += mat4(0.117895685136318,-0.252732336521149,-0.243032127618790,-0.223230078816414,0.174223572015762,-0.232460960745811,-0.197713643312454,-0.178540006279945,0.210268020629883,-0.229081839323044,0.190010055899620,-0.092014223337173,-0.064636573195457,0.373851358890533,0.495862782001495,0.487715750932693) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.289540797472000,0.042452536523342,0.129221618175507,-0.095700010657310,0.170972108840942,-0.093700893223286,0.031423065811396,-0.038706738501787,-0.077164530754089,-0.060889001935720,0.015546245500445,-0.059277150779963,0.005965831223875,0.014217023737729,-0.154789820313454,0.212384790182114) * MODEL5_texOff(vec2(1,1));
res += mat4(-0.085702903568745,-0.007909956388175,-0.003471173346043,-0.066219650208950,-0.023675087839365,0.021815055981278,0.098761633038521,-0.070627063512802,0.143878459930420,-0.075231000781059,-0.248625397682190,0.169478833675385,0.024833792820573,0.021212933585048,0.291630297899246,-0.048623397946358) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.208149209618568,-0.109678104519844,-0.272665858268738,-0.056115835905075,-0.080130845308304,-0.001269798143767,0.174451723694801,-0.259846985340118,0.033100005239248,-0.003743247361854,-0.405732482671738,0.041773710399866,-0.008499985560775,0.116435207426548,0.092568002641201,0.103012062609196) * MODEL6_texOff(vec2(-1,0));
res += mat4(0.130878344178200,0.035254377871752,-0.014974799007177,-0.068449713289738,-0.069376088678837,-0.003263029502705,0.082731120288372,-0.022346697747707,0.129356920719147,-0.096479594707489,-0.042001057416201,0.087434612214565,0.030219092965126,-0.072118587791920,-0.008368104696274,-0.120073460042477) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.233395472168922,0.039669457823038,0.142102614045143,0.031313888728619,0.222358405590057,-0.183162376284599,0.273398339748383,-0.416383177042007,0.091106034815311,-0.201090499758720,0.231509894132614,-0.103729471564293,0.119138576090336,0.078338444232941,-0.212269261479378,0.375769436359406) * MODEL6_texOff(vec2(0,-1));
res += mat4(-0.152055144309998,0.013008868321776,0.154031813144684,0.011462728492916,-0.156570211052895,0.438038259744644,0.617039799690247,0.132234334945679,0.131566286087036,-0.113100841641426,-0.334546715021133,-0.509754478931427,-0.069788582623005,0.150251761078835,-0.527465283870697,-0.307220578193665) * MODEL6_texOff(vec2(0,0));
res += mat4(0.323010146617889,-0.053264658898115,-0.040745858103037,-0.440447121858597,-0.094902366399765,-0.172260150313377,-0.023983033373952,-0.017102638259530,0.285562247037888,-0.033783745020628,0.007371362298727,0.219897195696831,-0.079963766038418,-0.234528660774231,-0.163088470697403,-0.226602122187614) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.043077424168587,0.046489875763655,-0.225733265280724,-0.073754891753197,-0.004020983818918,0.051387578248978,-0.200925931334496,0.028649166226387,-0.168446615338326,-0.032603602856398,0.272235035896301,0.204437479376793,0.042569804936647,-0.002195335924625,0.123796150088310,0.206422850489616) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.079958379268646,0.109429411590099,-0.047328226268291,0.103869602084160,-0.036706060171127,0.216178789734840,-0.376611649990082,0.166317999362946,0.074919894337654,0.114304274320602,0.290516197681427,-0.162374377250671,0.122171200811863,0.148153111338615,0.292503446340561,0.230392143130302) * MODEL6_texOff(vec2(1,0));
res += mat4(-0.005750983022153,-0.007905385456979,-0.019320555031300,-0.070461586117744,0.054135050624609,-0.009041179902852,0.042655661702156,-0.106532260775566,0.327133625745773,-0.042520266026258,0.241791263222694,-0.088495045900345,-0.099686726927757,-0.083523802459240,-0.058123748749495,0.053953889757395) * MODEL6_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.045787945389748,-0.272934943437576,0.343025147914886,0.905134737491608) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL4
//!BIND MODEL5
//!BIND MODEL6
//!SAVE MODEL3
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 3_3

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.019616529345512,0.122706651687622,-0.012462249025702,0.173574328422546);
res += mat4(0.192794770002365,-0.157075762748718,-0.055704921483994,-0.123584426939487,-0.254588663578033,-0.133381843566895,0.103667758405209,0.022217893972993,0.168491989374161,0.071056686341763,0.246394053101540,0.207879185676575,0.035355187952518,0.069212049245834,-0.009825682267547,0.080900974571705) * MODEL4_texOff(vec2(-1,-1));
res += mat4(0.304452568292618,-0.198764353990555,-0.012426485307515,-0.069859661161900,0.100021995604038,0.151422321796417,0.069370590150356,-0.139509543776512,-0.191546633839607,0.023581394925714,-0.208460211753845,0.040849804878235,0.005081993993372,0.295647621154785,-0.008396202698350,-0.108651295304298) * MODEL4_texOff(vec2(-1,0));
res += mat4(0.411571830511093,-0.152050897479057,0.171137019991875,-0.030203444883227,-0.014251490123570,-0.276309758424759,-0.100184522569180,0.036902785301208,0.035057004541159,0.102393023669720,0.001296789385378,0.052937243133783,0.180284395813942,0.053408473730087,-0.124936275184155,-0.093082882463932) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.295960396528244,-0.080845184624195,-0.089209370315075,-0.143751695752144,-0.116791680455208,-0.224045693874359,0.457503139972687,0.131240233778954,0.141142070293427,0.025562305003405,0.347212404012680,-0.230074137449265,0.075339861214161,-0.155648782849312,-0.155148983001709,-0.020958812907338) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.223345696926117,-0.108072519302368,-0.154894620180130,-0.030051071196795,0.299284726381302,0.405680269002914,-0.092269785702229,0.160362064838409,-0.192305848002434,-0.346828252077103,-0.374241262674332,-0.250753879547119,0.229160204529762,0.303509742021561,-0.296033173799515,0.353858560323715) * MODEL4_texOff(vec2(0,0));
res += mat4(0.343169480562210,-0.253298252820969,0.199079647660255,-0.256998956203461,-0.035477004945278,-0.235278740525246,0.072570823132992,0.199573084712029,0.011144950985909,0.208439081907272,0.015605658292770,-0.145083352923393,0.044957559555769,0.212195754051208,-0.116576224565506,-0.023414520546794) * MODEL4_texOff(vec2(0,1));
res += mat4(0.262070327997208,0.015520424582064,-0.155006751418114,-0.082406729459763,0.097260482609272,-0.065211221575737,-0.016861062496901,0.008742078207433,0.080973803997040,0.090888977050781,-0.008517784066498,0.155603170394897,-0.037555661052465,-0.077326931059361,0.001031160820276,-0.020729400217533) * MODEL4_texOff(vec2(1,-1));
res += mat4(0.240787968039513,-0.051990680396557,-0.088044784963131,0.046952161937952,-0.072701282799244,0.028310593217611,-0.099200814962387,-0.062155611813068,0.148722544312477,0.143429517745972,0.260512024164200,0.189778283238411,0.107232861220837,0.017329074442387,0.141884535551071,0.029138443991542) * MODEL4_texOff(vec2(1,0));
res += mat4(0.275236994028091,-0.034836448729038,0.219076409935951,-0.051433525979519,-0.072807431221008,-0.121751792728901,0.168412759900093,0.052146699279547,-0.054959673434496,-0.024697763845325,-0.390487670898438,0.036171738058329,-0.021770453080535,-0.045588623732328,-0.238632678985596,0.001307493308559) * MODEL4_texOff(vec2(1,1));
res += mat4(-0.114659838378429,-0.017971878871322,0.146689355373383,-0.013841780833900,0.036000862717628,-0.027261085808277,0.045098077505827,-0.020568620413542,-0.051943555474281,-0.105836570262909,-0.148182407021523,0.036748029291630,-0.293388456106186,0.121274426579475,-0.195006892085075,0.138004601001740) * MODEL5_texOff(vec2(-1,-1));
res += mat4(0.157460212707520,0.127158060669899,0.033315058797598,-0.103509217500687,0.182084590196609,-0.092257790267467,-0.190716445446014,0.504402518272400,0.020551040768623,-0.324994146823883,0.184483945369720,0.220699653029442,-0.790030360221863,0.166065335273743,0.011683010496199,0.014744188636541) * MODEL5_texOff(vec2(-1,0));
res += mat4(0.130792334675789,0.088539443910122,-0.300012201070786,0.008406140841544,-0.143299788236618,0.134031161665916,-0.119682244956493,0.096183344721794,0.027784006670117,-0.163110554218292,0.095170252025127,0.117353253066540,-0.303194701671600,0.272441834211349,-0.068284645676613,0.024435991421342) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.003285859245807,-0.081127375364304,0.325507521629333,0.000042906944145,0.169474199414253,0.120329745113850,-0.299696147441864,-0.179189562797546,-0.038174912333488,-0.210918799042702,-0.271105915307999,-0.170481801033020,-0.387901246547699,0.101380348205566,-0.064324028789997,0.060149241238832) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.009894871152937,0.156925633549690,0.392192184925079,-0.031215380877256,-0.168182879686356,-0.449102461338043,0.125135332345963,-0.683555424213409,-0.142196819186211,-0.903431177139282,0.430557996034622,-0.247978255152702,-0.421925783157349,0.062052030116320,0.071125254034996,-0.021346522495151) * MODEL5_texOff(vec2(0,0));
res += mat4(0.072696939110756,-0.012470120564103,-0.812555015087128,-0.016957586631179,-0.084966287016869,0.231048047542572,0.075261130928993,-0.034186471253633,-0.035531844943762,-0.240314632654190,0.416332572698593,0.083814933896065,-0.258745312690735,0.124872706830502,-0.079553499817848,0.119752071797848) * MODEL5_texOff(vec2(0,1));
res += mat4(0.125465914607048,-0.025685580447316,0.103156991302967,-0.028904899954796,-0.073009118437767,0.117440678179264,-0.121078506112099,0.029249053448439,0.122180715203285,0.013087318278849,-0.073516309261322,0.180098637938499,-0.122239276766777,0.145678162574768,-0.070758454501629,0.063550047576427) * MODEL5_texOff(vec2(1,-1));
res += mat4(-0.033622287213802,0.003829370485619,-0.068906486034393,0.130969405174255,0.090433180332184,0.164037346839905,0.093077644705772,0.572931647300720,-0.041364345699549,0.118511758744717,0.201073780655861,-0.133240848779678,-0.272054940462112,0.136256411671638,0.046738762408495,0.003652360988781) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.104349561035633,0.067317090928555,-0.207243502140045,0.045787345618010,0.217676237225533,-0.092099934816360,-0.042150072753429,0.051193799823523,0.024931725114584,-0.001270022010431,0.152906373143196,-0.024506889283657,-0.347211569547653,0.135721698403358,0.139290481805801,0.104297496378422) * MODEL5_texOff(vec2(1,1));
res += mat4(0.025649167597294,-0.032162379473448,0.186348468065262,-0.031209666281939,-0.098211660981178,-0.106036633253098,-0.245069473981857,0.143352672457695,-0.152808830142021,0.046614859253168,-0.084266863763332,-0.087636560201645,0.242588013410568,-0.071527153253555,-0.015568531118333,0.045482560992241) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.060541961342096,0.011988176964223,-0.179472357034683,-0.200691789388657,-0.251007169485092,-0.116536729037762,0.059493344277143,0.109580084681511,0.017246106639504,-0.077555686235428,0.087445460259914,-0.043577261269093,0.009372881613672,0.002746526850387,-0.056880708783865,-0.173366367816925) * MODEL6_texOff(vec2(-1,0));
res += mat4(-0.141562968492508,-0.003162967506796,0.129176497459412,-0.322928041219711,-0.131634101271629,-0.009280976839364,0.126634106040001,0.137532800436020,0.116430945694447,0.012689183466136,-0.028585044667125,-0.042380366474390,-0.153807178139687,0.044101133942604,-0.201933413743973,0.092997707426548) * MODEL6_texOff(vec2(-1,1));
res += mat4(0.125335693359375,-0.031170394271612,-0.220497459173203,-0.062889173626900,-0.333540916442871,-0.060159467160702,-0.073276028037071,0.056485153734684,-0.051402121782303,0.173779070377350,-0.201755851507187,-0.165226802229881,0.041074272245169,-0.056042801588774,0.020312560722232,0.065836675465107) * MODEL6_texOff(vec2(0,-1));
res += mat4(-0.203959435224533,-0.079071395099163,0.431243419647217,0.196483537554741,-0.620369613170624,-0.023084165528417,0.033247269690037,0.025495879352093,0.075987502932549,-0.150219917297363,0.180275171995163,0.002086283871904,0.097921945154667,0.261155962944031,0.228503718972206,-0.103944428265095) * MODEL6_texOff(vec2(0,0));
res += mat4(-0.188967719674110,0.178377091884613,-0.192673817276955,0.025922661647201,-0.065032869577408,-0.014586900360882,0.299445360898972,0.123788446187973,-0.023323863744736,0.028689844533801,0.073680311441422,-0.038087703287601,0.109278239309788,-0.055048730224371,-0.789848566055298,-0.097161941230297) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.182368442416191,0.028608381748199,-0.172728538513184,-0.178192570805550,-0.183503523468971,-0.085063099861145,-0.054795887321234,-0.076404534280300,-0.012821978889406,0.073447756469250,-0.001082403585315,-0.226943910121918,-0.098690994083881,-0.017833963036537,0.002084029838443,0.081014879047871) * MODEL6_texOff(vec2(1,-1));
res += mat4(0.093406118452549,0.004619341809303,0.136215746402740,-0.460926562547684,-0.191061601042747,-0.244276314973831,-0.097447350621223,0.046624843031168,-0.215154930949211,-0.117540493607521,-0.183474943041801,-0.470068871974945,0.052732624113560,-0.070786342024803,-0.126834020018578,0.092366360127926) * MODEL6_texOff(vec2(1,0));
res += mat4(0.203979849815369,0.142775699496269,-0.087712138891220,-0.274882286787033,-0.160304501652718,-0.106023758649826,0.269813746213913,-0.092635616660118,-0.036013528704643,0.056580722332001,0.230673849582672,-0.313629835844040,0.042535033077002,-0.173263996839523,0.117286220192909,0.302361726760864) * MODEL6_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.345697551965714,-0.083636738359928,-0.011613168753684,0.051181457936764) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(-0.091796606779099,0.113671898841858,0.037497315555811,-0.060786765068769);
res += mat4(-0.023233447223902,0.096722550690174,0.150643646717072,0.089345045387745,0.060655757784843,0.160836294293404,-0.106009379029274,0.051355220377445,0.089257098734379,0.177271261811256,-0.168400064110756,0.097023814916611,0.119689919054508,-0.120419934391975,0.053975168615580,-0.127927869558334) * MODEL4_texOff(vec2(-1,-1));
res += mat4(0.237650990486145,0.021049452945590,0.074257031083107,0.156517341732979,-0.245188295841217,-0.203244000673294,0.234686478972435,0.471207231283188,-0.107974365353584,-0.015265573747456,0.145521298050880,0.214126572012901,0.199694022536278,0.054565522819757,0.069068826735020,-0.129629433155060) * MODEL4_texOff(vec2(-1,0));
res += mat4(0.046174902468920,0.129180967807770,-0.081196919083595,-0.088281057775021,0.077078908681870,-0.043721113353968,-0.155704751610756,-0.002180969342589,0.106425873935223,0.167381554841995,0.190457791090012,0.203462183475494,-0.088182158768177,-0.015905532985926,-0.132137477397919,-0.155713424086571) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.101931467652321,0.482824862003326,0.098664022982121,-0.270351529121399,-0.090128436684608,0.009729750454426,0.045824728906155,-0.056407015770674,0.145252600312233,0.105518504977226,0.008087392896414,0.166756525635719,0.063428483903408,-0.464974611997604,0.472782671451569,0.001561865094118) * MODEL4_texOff(vec2(0,-1));
res += mat4(-0.195010200142860,0.237645089626312,-0.050138156861067,-0.428471773862839,-0.279800057411194,-0.031963970512152,-0.072776198387146,0.174072042107582,0.191861435770988,0.055864587426186,0.210406199097633,0.632774055004120,0.136677935719490,0.392957150936127,0.050558406859636,-0.256773799657822) * MODEL4_texOff(vec2(0,0));
res += mat4(0.253855288028717,0.005895466543734,0.013712015002966,0.078075423836708,0.582500159740448,-0.179793924093246,-0.220177710056305,-0.163782849907875,0.346454858779907,0.143946990370750,-0.081549964845181,0.206338346004486,0.001066257245839,-0.231760129332542,-0.220275804400444,-0.107153467833996) * MODEL4_texOff(vec2(0,1));
res += mat4(0.099001914262772,-0.181151047348976,-0.204415902495384,-0.154293239116669,-0.092441648244858,-0.218967199325562,-0.023942613974214,0.298762828111649,0.003135693259537,0.024053150787950,0.033804673701525,-0.215958863496780,-0.110461436212063,0.124790273606777,0.074261993169785,0.086262479424477) * MODEL4_texOff(vec2(1,-1));
res += mat4(0.388443976640701,-0.090246379375458,-0.152031034231186,-0.148165062069893,0.376139670610428,-0.286209821701050,-0.288400441408157,0.152342990040779,0.006449792999774,-0.119011051952839,-0.028954381123185,-0.232587665319443,-0.420582264661789,0.003134775208309,-0.292730391025543,0.061848349869251) * MODEL4_texOff(vec2(1,0));
res += mat4(0.065440326929092,0.079346157610416,0.165914580225945,0.036456294357777,0.292216569185257,-0.132318496704102,-0.084257327020168,0.117432698607445,0.298689931631088,-0.117359161376953,0.002021448221058,-0.086732149124146,-0.001689366879873,-0.009572263807058,-0.046393286436796,0.105440184473991) * MODEL4_texOff(vec2(1,1));
res += mat4(-0.045347157865763,0.043590709567070,-0.071592174470425,0.182604700326920,0.030331548303366,-0.105958215892315,-0.133495867252350,-0.138715282082558,0.015473182313144,-0.224941715598106,-0.122856318950653,-0.120888516306877,0.062332350760698,-0.012826474383473,-0.063762538135052,0.030794734135270) * MODEL5_texOff(vec2(-1,-1));
res += mat4(-0.087448202073574,0.113200247287750,0.054270364344120,0.272727668285370,-0.002016777405515,-0.044586591422558,-0.016878088936210,0.026121465489268,0.305757313966751,-0.076166525483131,-0.318862438201904,-0.219505503773689,-0.281925976276398,0.121433436870575,0.058154281228781,0.263015329837799) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.012943716719747,-0.102590575814247,-0.112636193633080,0.082958929240704,-0.037179090082645,0.028444353491068,-0.035124950110912,-0.051884517073631,0.010238209739327,0.083281829953194,-0.085774518549442,-0.069299168884754,0.071514189243317,0.007234751246870,0.029301458969712,0.170059233903885) * MODEL5_texOff(vec2(-1,1));
res += mat4(0.021812573075294,-0.046081520617008,0.034663535654545,0.059754762798548,-0.069077990949154,-0.657195985317230,-0.203988343477249,0.557337820529938,-0.014124863781035,-0.391671150922775,-0.138103336095810,0.434898078441620,0.024953408166766,0.021795516833663,-0.105093687772751,0.028563059866428) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.237733438611031,-0.019773980602622,-0.279590636491776,-0.122851163148880,0.051556471735239,-0.047386180609465,-0.188192605972290,0.120920173823833,0.269364267587662,-0.199681967496872,-0.136815786361694,0.490411698818207,-0.019470717757940,0.467623919248581,0.063052520155907,-0.211759015917778) * MODEL5_texOff(vec2(0,0));
res += mat4(0.131835326552391,-0.119755201041698,-0.099824570119381,0.034368313848972,0.038731426000595,-0.163271993398666,-0.144070655107498,-0.050485651940107,0.074911393225193,0.024949062615633,0.168335795402527,0.150609195232391,0.015749139711261,0.087333559989929,0.019836399704218,-0.106024675071239) * MODEL5_texOff(vec2(0,1));
res += mat4(0.001322585041635,-0.018764263018966,-0.140248358249664,-0.036393173038960,-0.060379754751921,-0.213690981268883,-0.194497078657150,-0.074739262461662,0.141784697771072,-0.161830142140388,-0.266570240259171,0.128610655665398,0.043242707848549,0.024961283430457,-0.360922276973724,-0.353589624166489) * MODEL5_texOff(vec2(1,-1));
res += mat4(0.479054450988770,-0.414033919572830,-0.394169032573700,0.093372330069542,0.228577733039856,-0.094876274466515,-0.070933677256107,-0.075011216104031,0.309115409851074,0.145924046635628,0.058680143207312,-0.291794568300247,-0.466759771108627,0.342797577381134,0.063549667596817,-0.323324173688889) * MODEL5_texOff(vec2(1,0));
res += mat4(0.170302033424377,-0.018758350983262,0.092637449502945,0.313201218843460,0.058374375104904,-0.057928215712309,0.134393453598022,0.140850543975830,-0.017891131341457,0.119681574404240,0.081432528793812,-0.072010725736618,-0.118842840194702,0.014879415743053,0.023913057520986,0.196949988603592) * MODEL5_texOff(vec2(1,1));
res += mat4(0.003533662296832,0.096051193773746,0.017783258110285,-0.169084459543228,-0.025249410420656,0.031475849449635,0.036351956427097,0.041828874498606,-0.119204208254814,0.120646283030510,-0.020503506064415,0.191196143627167,-0.118485756218433,0.166918054223061,0.009586965665221,-0.355047523975372) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.068909876048565,-0.127839431166649,-0.143295243382454,-0.216495350003242,-0.112046115100384,0.014080197550356,0.112549945712090,0.203420683741570,0.019451277330518,0.020654745399952,0.117250785231590,0.331533044576645,0.000274566875305,0.059557989239693,0.263315230607986,-0.182172596454620) * MODEL6_texOff(vec2(-1,0));
res += mat4(0.086108043789864,-0.003497421042994,0.129086419939995,-0.040269169956446,-0.035671908408403,-0.046021956950426,-0.058766227215528,-0.011526484973729,-0.022904528304935,0.076733261346817,-0.023686619475484,-0.123553954064846,0.069757856428623,-0.138236239552498,0.260756641626358,0.100904949009418) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.044818513095379,-0.141591832041740,0.308577030897141,-0.168986812233925,-0.047987595200539,-0.213828951120377,-0.054312217980623,-0.414422571659088,0.152079924941063,0.320628553628922,-0.178428590297699,-0.197414293885231,0.135556295514107,0.186445772647858,0.238440975546837,0.127198264002800) * MODEL6_texOff(vec2(0,-1));
res += mat4(0.167623043060303,0.121673963963985,0.283391684293747,0.050185825675726,-0.306755036115646,0.493940979242325,0.378180623054504,-0.441614955663681,0.199024066329002,-0.518309712409973,-0.325452983379364,-0.257709980010986,0.040329236537218,0.077742911875248,0.133894234895706,0.183625131845474) * MODEL6_texOff(vec2(0,0));
res += mat4(0.010178478434682,0.047137502580881,0.175005346536636,0.084926307201385,-0.063765093684196,-0.366631269454956,-0.247486606240273,-0.030811930075288,0.412046074867249,0.197557255625725,0.087631277740002,-0.185039237141609,-0.120199650526047,0.242349386215210,0.020626956596971,0.168750554323196) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.044645674526691,0.343025296926498,0.088947221636772,-0.039301171898842,0.004795661196113,-0.125020936131477,-0.065678909420967,0.135007306933403,-0.093888036906719,0.028962774202228,-0.045003168284893,0.011045976541936,-0.161564290523529,0.126664370298386,0.252992242574692,-0.003131766105071) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.122593738138676,-0.060690388083458,-0.077653080224991,-0.250300228595734,-0.178662151098251,0.210162952542305,0.152677863836288,0.146286755800247,-0.126166418194771,0.352140367031097,0.058290116488934,-0.033266779035330,-0.049720004200935,0.133504241704941,0.052877474576235,-0.281848996877670) * MODEL6_texOff(vec2(1,0));
res += mat4(0.073484808206558,0.058236189186573,0.016532687470317,-0.136877134442329,-0.153341993689537,-0.117922388017178,0.056421179324389,-0.076530382037163,0.090515084564686,0.050298728048801,0.298183053731918,-0.059327561408281,0.031100580468774,-0.019430104643106,-0.091534622013569,-0.204739019274712) * MODEL6_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.027029991149902,0.518537998199463,-0.745807886123657,-0.050700858235359) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL1
//!BIND MODEL2
//!BIND MODEL3
//!SAVE MODEL4
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 4_1

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.001063551288098,-0.204284518957138,-0.183830991387367,-0.352517604827881);
res += mat4(0.017108375206590,-0.173584789037704,-0.116419181227684,-0.056901045143604,-0.000817023566924,-0.231059312820435,-0.158049091696739,0.101301617920399,-0.060959991067648,-0.067267119884491,0.010329516604543,0.075357556343079,-0.012783928774297,0.016294054687023,0.018521590158343,0.162300765514374) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.007265480700880,-0.147562757134438,-0.045945499092340,-0.071262754499912,0.000903589127120,0.107929490506649,0.008603880181909,0.302787899971008,-0.002421062206849,0.143366068601608,0.207432076334953,-0.010740351863205,-0.222473263740540,-0.063833676278591,-0.126344919204712,0.500773012638092) * MODEL1_texOff(vec2(-1,0));
res += mat4(-0.030843211337924,-0.178807631134987,-0.172968566417694,0.012967404909432,0.026986066251993,-0.017206037417054,-0.135625347495079,0.039634946733713,0.016619050875306,0.048940308392048,-0.027942681685090,-0.056613437831402,-0.092888116836548,0.014445813372731,0.081399999558926,0.159770295023918) * MODEL1_texOff(vec2(-1,1));
res += mat4(-0.006168167572469,-0.072339229285717,-0.220074012875557,-0.133761644363403,-0.037570685148239,-0.268627643585205,0.035889793187380,-0.049430195242167,-0.247008398175240,0.432325094938278,-0.291312485933304,-0.070064932107925,0.077713169157505,0.031425088644028,-0.127173766493797,-0.106748938560486) * MODEL1_texOff(vec2(0,-1));
res += mat4(-0.024861067533493,-0.095523044466972,0.088369950652122,0.120072178542614,0.002946816617623,0.473877608776093,0.203182771801949,-0.177658885717392,0.206738233566284,-0.510825574398041,0.056056510657072,-0.093248814344406,0.212834537029266,-0.097489677369595,0.361831814050674,-0.187149316072464) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.010121482424438,0.040411885827780,-0.082140274345875,0.043630030006170,0.095072627067566,-0.160067468881607,-0.170974627137184,-0.085931725800037,-0.007625537458807,0.148959130048752,0.220505774021149,-0.059149660170078,0.019902685657144,0.073830753564835,-0.233282700181007,-0.037821669131517) * MODEL1_texOff(vec2(0,1));
res += mat4(0.030663307756186,-0.150492548942566,-0.130295008420944,-0.022908324375749,-0.032952994108200,-0.008044466376305,-0.088560178875923,-0.005139125511050,-0.044550109654665,0.252033352851868,0.141307801008224,-0.027779722586274,0.027433199808002,0.048119999468327,0.046688396483660,-0.040065713226795) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.003339262213558,-0.126344278454781,-0.095846019685268,0.008077388629317,0.009171201847494,0.096023112535477,0.040096405893564,0.003124278271571,0.017412312328815,-0.134296506643295,-0.041392695158720,-0.028056040406227,-0.077402561903000,0.048139665275812,-0.053693417459726,-0.066758506000042) * MODEL1_texOff(vec2(1,0));
res += mat4(0.031434077769518,-0.128464356064796,-0.080632992088795,-0.000444139674073,0.037802714854479,-0.246731787919998,-0.181931793689728,0.002763803349808,-0.004415953066200,-0.109667703509331,0.073007635772228,-0.015133243985474,-0.012695397250354,-0.012195543386042,0.062521919608116,-0.023141616955400) * MODEL1_texOff(vec2(1,1));
res += mat4(-0.009034433402121,-0.026202656328678,-0.023006234318018,-0.002988763852045,0.012206439860165,0.071756653487682,-0.051844108849764,-0.118960313498974,-0.023917837068439,-0.047637071460485,-0.078614972531796,-0.002517874352634,-0.036637868732214,-0.048718091100454,0.037725064903498,-0.267248511314392) * MODEL2_texOff(vec2(-1,-1));
res += mat4(0.008144140243530,0.046487201005220,-0.095338195562363,0.117241576313972,0.055068239569664,-0.136366054415703,0.079152591526508,-0.687411665916443,-0.045159310102463,0.155487045645714,0.139124080538750,-0.042276844382286,-0.037860203534365,-0.136806651949883,-0.087375789880753,-0.225791767239571) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.034340430051088,0.153125450015068,0.185702547430992,0.027261266484857,0.023943280801177,0.061027258634567,-0.053099509328604,-0.040369153022766,-0.006180915981531,0.036687005311251,-0.006103043910116,-0.027621403336525,-0.079942263662815,0.207326158881187,0.073212981224060,0.061529725790024) * MODEL2_texOff(vec2(-1,1));
res += mat4(-0.050115663558245,-0.165181279182434,0.150130540132523,-0.062488138675690,-0.046166159212589,-0.178802400827408,-0.006124068517238,0.083902947604656,-0.203804343938828,-0.169556587934494,0.080710582435131,-0.099465228617191,0.027741331607103,-0.040649335831404,0.156615287065506,-0.166961714625359) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.233219265937805,0.392732530832291,-0.112478718161583,-0.053149733692408,0.087498366832733,0.223533183336258,-0.088248670101166,0.252130806446075,0.183269947767258,0.453890532255173,0.153356477618217,-0.222326099872589,-0.117544151842594,-0.335582822561264,-0.195260822772980,-0.195243433117867) * MODEL2_texOff(vec2(0,0));
res += mat4(-0.214338615536690,0.406869739294052,0.559208512306213,-0.007058545481414,-0.000942402170040,0.012428555637598,0.177545204758644,-0.016253739595413,0.000784536125138,-0.000798293040134,-0.109627828001976,-0.038847461342812,0.150863885879517,0.406544715166092,0.282256156206131,-0.052713658660650) * MODEL2_texOff(vec2(0,1));
res += mat4(0.010988919995725,-0.060147080570459,-0.038816187530756,-0.014225578866899,-0.022795882076025,-0.075929842889309,-0.061632111668587,-0.084640696644783,0.006668175570667,-0.063044413924217,-0.002256975974888,-0.019408734515309,0.019763914868236,-0.002823740709573,0.069619290530682,0.035287886857986) * MODEL2_texOff(vec2(1,-1));
res += mat4(0.000796048436314,0.258174389600754,-0.010279000736773,-0.056021146476269,-0.135097891092300,-0.102620117366314,0.090866275131702,0.036554668098688,0.062398128211498,0.069367565214634,0.110070131719112,-0.080540195107460,0.111724324524403,0.132355749607086,-0.140926107764244,-0.076941348612309) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.049569796770811,0.148122668266296,0.251461833715439,-0.039390288293362,-0.022554520517588,-0.000761701259762,-0.036743026226759,-0.030263254418969,0.058226116001606,0.024853006005287,-0.027872214093804,0.001091987127438,0.018723718822002,-0.064275361597538,0.265588402748108,-0.023572852835059) * MODEL2_texOff(vec2(1,1));
res += mat4(-0.028851103037596,-0.107732675969601,-0.115119002759457,0.093065008521080,0.016385532915592,-0.013083724305034,0.079594433307648,-0.261457413434982,0.034067291766405,0.027300359681249,0.063548207283020,0.020270410925150,0.005643968936056,-0.055140174925327,0.052631102502346,-0.091940045356750) * MODEL3_texOff(vec2(-1,-1));
res += mat4(-0.018870294094086,0.046625591814518,-0.029049539938569,0.019790796563029,-0.031188169494271,0.062680095434189,-0.059381585568190,0.047495923936367,0.002167862141505,-0.000254951562965,-0.006511911749840,-0.193079695105553,-0.076317273080349,0.242843106389046,0.022116634994745,0.081966698169708) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.019240533933043,-0.028585620224476,0.013996944762766,-0.197609186172485,0.007960382848978,-0.085299544036388,0.007247671484947,0.068024344742298,-0.002215473679826,-0.127501964569092,-0.008710680529475,-0.126920595765114,-0.014109126292169,-0.163790389895439,-0.026166202500463,0.019887292757630) * MODEL3_texOff(vec2(-1,1));
res += mat4(0.009960415773094,0.065319336950779,0.088456235826015,-0.210530623793602,-0.024231836199760,0.272127628326416,-0.197200939059258,0.000554442231078,0.078382886946201,-0.012356298044324,0.327150166034698,-0.046255677938461,-0.053898368030787,0.096685975790024,0.152617245912552,0.201411768794060) * MODEL3_texOff(vec2(0,-1));
res += mat4(0.021164484322071,0.030332162976265,0.019339138641953,-0.091370895504951,0.066428512334824,-0.202362135052681,-0.164465159177780,-0.117677167057991,-0.085801959037781,0.440649747848511,-1.003569841384888,0.062214910984039,0.074304655194283,0.079148046672344,0.039309706538916,0.566178619861603) * MODEL3_texOff(vec2(0,0));
res += mat4(-0.002355000469834,-0.071793287992477,0.058622486889362,0.041147723793983,0.021071564406157,-0.308064639568329,0.035217750817537,-0.055312991142273,-0.001296278205700,-0.164813339710236,-0.100796483457088,0.011542170308530,0.000180373579497,-0.011720992624760,-0.135207861661911,0.024503486230969) * MODEL3_texOff(vec2(0,1));
res += mat4(0.031149474903941,-0.065730370581150,0.013871058821678,0.054772067815065,-0.014239284209907,0.000721566262655,0.075664684176445,0.044004473835230,0.022126924246550,0.017785601317883,0.141192868351936,-0.035128567367792,-0.023506768047810,0.070606335997581,-0.052713457494974,0.084817767143250) * MODEL3_texOff(vec2(1,-1));
res += mat4(-0.005485665518790,0.026744559407234,-0.048879548907280,0.111134938895702,0.020760111510754,-0.092082768678665,-0.042751323431730,0.066265836358070,0.014653045684099,-0.191799864172935,-0.287059187889099,0.038765374571085,-0.002153701614588,0.023693062365055,0.128983229398727,0.158170521259308) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.027414033189416,0.002755100373179,0.107373923063278,0.029923452064395,0.054517764598131,-0.011829630471766,-0.065043114125729,-0.014921505935490,-0.014617391861975,-0.014412612654269,-0.145859777927399,-0.001343789161183,0.006714074872434,0.015757059678435,-0.024067517369986,0.084915667772293) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(1.008100032806396,0.056351259350777,0.014320693910122,-0.006850216537714) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(-0.185582861304283,-0.247326552867889,-0.075649358332157,0.000369130924810);
res += mat4(-0.052615590393543,-0.193395420908928,-0.065762758255005,-0.075509324669838,0.141949132084846,0.268261015415192,0.016199465841055,0.057271867990494,0.014413841068745,0.211411684751511,-0.128946796059608,-0.015370544046164,0.200984567403793,0.230808123946190,0.012311434373260,0.096731707453728) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.036959622055292,-0.135517850518227,0.071128338575363,-0.078668400645256,0.177078276872635,0.362657696008682,-0.037101149559021,0.200807332992554,-0.057412263005972,-0.041792288422585,-0.084015905857086,-0.125615075230598,0.089210681617260,0.201756924390793,0.054286010563374,0.211332947015762) * MODEL1_texOff(vec2(-1,0));
res += mat4(0.071381889283657,0.051769785583019,-0.070612415671349,0.127343088388443,-0.063436120748520,0.055014301091433,-0.020292354747653,-0.035175886005163,-0.009667838923633,0.102342627942562,0.001733642537147,0.006183710880578,-0.042364299297333,0.044838406145573,-0.065641015768051,0.028079407289624) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.121156342327595,0.043912779539824,-0.184037446975708,-0.045521695166826,0.040433023124933,-0.149565681815147,0.042236596345901,-0.052300471812487,0.051886267960072,0.082075826823711,-0.097603701055050,-0.168173596262932,-0.199787780642509,0.022128740325570,-0.010636989958584,-0.072173647582531) * MODEL1_texOff(vec2(0,-1));
res += mat4(-0.454142153263092,-0.163926079869270,0.204899385571480,0.007258119527251,0.174312636256218,-0.262234866619110,0.028694685548544,-0.168282598257065,-0.002789080841467,0.060680061578751,0.117575906217098,0.460924923419952,0.054783370345831,0.396587669849396,-0.234290689229965,-0.034260191023350) * MODEL1_texOff(vec2(0,0));
res += mat4(0.035416088998318,-0.044737420976162,-0.158326536417007,-0.101461037993431,0.069664523005486,-0.015879381448030,0.117278307676315,-0.231828868389130,0.036253012716770,0.047956660389900,0.048103045672178,-0.033964619040489,0.199985086917877,0.146915659308434,0.139573648571968,-0.026733743026853) * MODEL1_texOff(vec2(0,1));
res += mat4(0.040817152708769,0.090609349310398,0.017387567088008,0.032426469027996,0.088546857237816,0.075333140790462,0.086193867027760,-0.029380688443780,0.074453517794609,-0.232232883572578,-0.091236181557178,-0.067843690514565,0.148694500327110,-0.083762384951115,0.115056842565536,-0.049685351550579) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.253684222698212,0.272051185369492,-0.157766744494438,-0.051989406347275,-0.075967684388161,0.209525391459465,0.140323892235756,0.080536335706711,0.014069873839617,0.085534207522869,0.025733044371009,-0.135928496718407,0.121493525803089,-0.194834679365158,0.112716309726238,-0.127185553312302) * MODEL1_texOff(vec2(1,0));
res += mat4(0.137072786688805,-0.041733197867870,-0.190939113497734,-0.001597705180757,0.014997049234807,0.058538153767586,-0.076942399144173,0.075450681149960,-0.024728532880545,-0.069867774844170,0.074427679181099,-0.046520091593266,-0.047895871102810,-0.055185101926327,-0.009662186726928,-0.099297262728214) * MODEL1_texOff(vec2(1,1));
res += mat4(-0.080227240920067,-0.037781592458487,0.189076110720634,-0.140819489955902,-0.063585229218006,0.178733825683594,0.053705193102360,0.018406076356769,0.240942761301994,-0.071082301437855,-0.001799816731364,0.009167066775262,0.144063174724579,-0.109966732561588,-0.076590828597546,0.013743986375630) * MODEL2_texOff(vec2(-1,-1));
res += mat4(0.177926346659660,0.048716150224209,-0.276671826839447,-0.034161087125540,-0.063399396836758,0.001835768343881,-0.070481717586517,0.035163104534149,0.352691769599915,-0.379519134759903,0.029693000018597,0.034299384802580,0.180663540959358,0.080793529748917,-0.197991818189621,0.003625293727964) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.040732581168413,-0.184957027435303,0.120168067514896,0.048736743628979,-0.053075756877661,-0.012463578954339,0.058844223618507,-0.054728284478188,-0.073403760790825,-0.217853367328644,0.078122720122337,0.041155382990837,0.048310313373804,-0.084719501435757,0.207449749112129,0.001238851575181) * MODEL2_texOff(vec2(-1,1));
res += mat4(-0.026939755305648,-0.114748142659664,0.454705834388733,0.045348480343819,-0.086427636444569,-0.089721851050854,0.147796615958214,-0.126430183649063,0.179917290806770,0.037340115755796,-0.251773625612259,0.014176957309246,0.068062365055084,-0.000523879018147,0.097294047474861,0.125928208231926) * MODEL2_texOff(vec2(0,-1));
res += mat4(-0.165488645434380,-0.114981107413769,-0.428903609514236,-0.156625807285309,0.280281424522400,0.067277453839779,-0.410634309053421,0.096563413739204,-0.905094563961029,0.162151440978050,-0.259541094303131,-0.034924015402794,-0.049156971275806,-0.062931068241596,-0.831699788570404,-0.426105797290802) * MODEL2_texOff(vec2(0,0));
res += mat4(-0.005610188934952,0.223503246903419,0.383284032344818,0.242933660745621,0.026932634413242,0.008463220670819,0.285137087106705,-0.004276137333363,-0.065065227448940,0.039810437709093,0.059102915227413,0.067560136318207,0.175790742039680,0.108306132256985,0.501280605792999,0.329587846994400) * MODEL2_texOff(vec2(0,1));
res += mat4(0.038125637918711,0.133702680468559,0.303968578577042,0.003204154549167,-0.190355062484741,-0.024127557873726,-0.006459365598857,-0.021438896656036,-0.028612114489079,0.025729397311807,-0.072697415947914,-0.015310528688133,-0.114036157727242,0.123542621731758,0.072188720107079,-0.031416814774275) * MODEL2_texOff(vec2(1,-1));
res += mat4(-0.043833464384079,0.006206657271832,0.139611124992371,-0.097277119755745,-0.213085845112801,0.125631451606750,-0.024318775162101,0.028268011286855,-0.140383630990982,-0.134105831384659,-0.149475350975990,-0.002095225267112,0.163933962583542,0.192730069160461,-0.193320855498314,0.133980408310890) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.002340544713661,-0.076504841446877,-0.106341011822224,0.002945231040940,0.063312575221062,0.072761557996273,0.138312801718712,0.060737967491150,-0.037011370062828,0.005666966550052,0.047324519604445,-0.024783797562122,0.071876108646393,-0.030909409746528,0.172949358820915,0.054143875837326) * MODEL2_texOff(vec2(1,1));
res += mat4(-0.021987417712808,-0.499833911657333,-0.063784062862396,-0.112433210015297,-0.121665246784687,-0.132004857063293,-0.155910432338715,-0.020438237115741,-0.012555475346744,0.017941102385521,-0.183786258101463,0.028971230611205,-0.103966861963272,0.186690837144852,0.064324915409088,0.044510297477245) * MODEL3_texOff(vec2(-1,-1));
res += mat4(-0.011396735906601,-0.248826161026955,-0.050860043615103,-0.200108230113983,0.013798023574054,-0.147929891943932,-0.265627562999725,-0.006046120543033,-0.021807007491589,0.062622405588627,-0.043635793030262,-0.013600518926978,0.302496612071991,0.433400213718414,0.001409301883541,0.170908123254776) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.026937192305923,-0.034601133316755,0.011075532995164,-0.028391044586897,0.026634536683559,0.077756084501743,-0.059412080794573,-0.025141224265099,0.052884716540575,-0.050300817936659,0.040299154818058,-0.024791337549686,0.112849980592728,0.178064286708832,-0.048527199774981,0.128966048359871) * MODEL3_texOff(vec2(-1,1));
res += mat4(-0.008348717354238,0.052041381597519,-0.327798455953598,0.222413957118988,0.051324252039194,0.111826799809933,0.148436918854713,0.063109606504440,-0.020005719736218,0.023217542096972,0.093558765947819,-0.084350965917110,0.124892339110374,-0.087149001657963,-0.108081072568893,0.009115069173276) * MODEL3_texOff(vec2(0,-1));
res += mat4(-0.196856915950775,-0.132850512862206,-0.101960189640522,0.214186459779739,-0.322593629360199,0.104872308671474,-0.280108451843262,-0.101120173931122,0.245972946286201,-0.058007258921862,-0.131866276264191,0.077810980379581,0.217792019248009,0.432099163532257,-0.037426702678204,-0.242166593670845) * MODEL3_texOff(vec2(0,0));
res += mat4(0.092536166310310,0.015223427675664,0.184757277369499,0.167333424091339,-0.065247446298599,-0.124754562973976,-0.242251962423325,-0.204064682126045,0.082050628960133,0.052773725241423,0.235399320721626,0.108785048127174,0.118712887167931,-0.037854883819818,-0.303620725870132,-0.142352536320686) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.030653407797217,0.096418909728527,-0.020869711413980,-0.028623629361391,-0.047647349536419,0.024811467155814,-0.086313277482986,0.062381252646446,0.008630389347672,0.071694433689117,0.064813271164894,0.015392430126667,0.175413325428963,-0.109289802610874,-0.181410506367683,0.015648806467652) * MODEL3_texOff(vec2(1,-1));
res += mat4(0.105797946453094,0.240866854786873,-0.064783915877342,-0.072718419134617,-0.080336607992649,0.069478832185268,0.041578155010939,0.121177799999714,0.209034219384193,0.081142812967300,-0.085596576333046,-0.088074654340744,-0.229032143950462,-0.262543827295303,-0.096225991845131,0.080339893698692) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.049913723021746,-0.081872604787350,-0.081756301224232,-0.031112780794501,-0.158712252974510,0.176537886261940,-0.249125927686691,-0.147457942366600,0.008980898186564,-0.097456358373165,-0.056472472846508,0.106164932250977,0.003848847234622,0.050604026764631,-0.023101549595594,-0.059297896921635) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(-0.006693644449115,0.140334665775299,0.047924049198627,1.035767793655396) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL1
//!BIND MODEL2
//!BIND MODEL3
//!SAVE MODEL5
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 4_2

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.191490083932877,-0.168758615851402,-0.209225833415985,-0.221242904663086);
res += mat4(0.110214836895466,-0.163921549916267,0.112449109554291,-0.000531425874215,0.019178833812475,-0.239808082580566,0.069354072213173,0.066153436899185,0.265093892812729,-0.029441215097904,0.268735498189926,-0.048130918294191,-0.011315194889903,0.032105524092913,0.072999790310860,0.122059702873230) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.069976225495338,-0.052911639213562,0.138361036777496,-0.007383334450424,0.013854581862688,-0.065162703394890,-0.041572820395231,0.108685642480850,-0.058442063629627,0.132837712764740,-0.030955731868744,-0.141211092472076,0.074015982449055,0.055784780532122,-0.027909977361560,-0.007237416692078) * MODEL1_texOff(vec2(-1,0));
res += mat4(0.035133231431246,-0.131107807159424,-0.054433751851320,0.061475206166506,0.062463037669659,-0.140926331281662,0.016596142202616,-0.083581060171127,-0.009011293761432,0.033729460090399,0.100301876664162,0.112362205982208,-0.090065531432629,0.018935386091471,-0.107711777091026,-0.037947315722704) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.074917711317539,-0.085910886526108,-0.056120596826077,0.072629965841770,-0.055760715156794,-0.161682233214378,-0.010217585600913,0.089047819375992,0.294605970382690,0.533247232437134,-0.410985857248306,0.115085698664188,-0.034940261393785,-0.002566103823483,-0.143305748701096,-0.053078856319189) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.062884017825127,0.141735494136810,0.318860441446304,0.512984514236450,0.756955027580261,0.018327238038182,0.440162867307663,-0.164403438568115,-0.354744851589203,0.700459480285645,0.013063741847873,0.009610977955163,0.077062398195267,0.125976175069809,0.370285600423813,-0.141122922301292) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.053725674748421,-0.237904101610184,0.127915814518929,0.123483173549175,-0.189824983477592,0.117862902581692,-0.008703627623618,0.150273561477661,0.101701177656651,-0.065961085259914,0.205651059746742,-0.055908471345901,-0.040693473070860,-0.121965296566486,-0.046422045677900,0.100110791623592) * MODEL1_texOff(vec2(0,1));
res += mat4(0.000735608336981,-0.188211888074875,0.057288184762001,0.086539946496487,0.032594121992588,-0.036197416484356,-0.105075314640999,-0.111785203218460,0.056227002292871,0.157335355877876,0.049848202615976,0.024651750922203,0.107540138065815,0.029900556430221,0.069642163813114,-0.091373287141323) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.003804177744314,0.024138659238815,0.067115753889084,-0.060516670346260,0.016133731231093,-0.038592997938395,0.057787388563156,-0.003594179404899,0.129654139280319,-0.003827885724604,0.238933488726616,0.047903940081596,-0.165624052286148,-0.006655554752797,-0.094002865254879,0.378390133380890) * MODEL1_texOff(vec2(1,0));
res += mat4(0.143574386835098,-0.228953018784523,0.149887233972549,-0.024650167673826,0.088375315070152,-0.222026258707047,0.043318524956703,0.080669365823269,0.070105127990246,0.058967236429453,-0.066434636712074,0.012433467432857,0.039408966898918,0.065674081444740,0.025155110284686,0.063778415322304) * MODEL1_texOff(vec2(1,1));
res += mat4(-0.129654943943024,-0.090178832411766,-0.108034506440163,-0.010810204781592,-0.011879395693541,-0.079638965427876,-0.112343706190586,-0.090130701661110,-0.050669591873884,-0.053183805197477,-0.091413736343384,-0.159297406673431,-0.028852829709649,-0.070988737046719,-0.019919162616134,-0.024505158886313) * MODEL2_texOff(vec2(-1,-1));
res += mat4(0.023347523063421,-0.209355220198631,0.081703878939152,0.045758683234453,-0.009038278833032,0.046974178403616,0.026285171508789,-0.356040477752686,-0.048473846167326,0.097258754074574,0.049416344612837,-0.203085035085678,0.028008922934532,-0.090029664337635,-0.076751545071602,0.009343942627311) * MODEL2_texOff(vec2(-1,0));
res += mat4(0.135588496923447,0.222375154495239,0.024464892223477,-0.162006020545959,-0.079626560211182,0.020422222092748,0.049558099359274,-0.016094023361802,0.014433048665524,-0.023255251348019,-0.087185457348824,-0.109890632331371,0.008497427217662,0.079143635928631,0.214905634522438,-0.046719454228878) * MODEL2_texOff(vec2(-1,1));
res += mat4(-0.215078979730606,0.046746250241995,0.083600699901581,0.005819785874337,-0.010837393812835,-0.029287906363606,0.010703876614571,0.149854347109795,-0.041795048862696,0.116395734250546,0.026526760309935,0.134768024086952,-0.034345284104347,0.068726196885109,0.137324720621109,0.010968002490699) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.716175556182861,-0.643073379993439,-0.006996712181717,-0.341097444295883,-0.313233196735382,-0.195359781384468,0.011127204634249,0.590318024158478,0.165513455867767,-0.396939158439636,0.071824826300144,0.321237653493881,0.047131601721048,-0.271279901266098,-0.231225296854973,-0.372969269752502) * MODEL2_texOff(vec2(0,0));
res += mat4(0.278500199317932,0.546761691570282,0.141813337802887,0.269532203674316,0.006559290923178,0.126468434929848,-0.118693143129349,0.014713547192514,-0.031529940664768,0.113427117466927,-0.054133526980877,0.005026562139392,0.114854581654072,0.175081670284271,0.391140341758728,-0.014988448470831) * MODEL2_texOff(vec2(0,1));
res += mat4(-0.060679439455271,0.046708464622498,-0.020437905564904,-0.109241932630539,-0.112664550542831,-0.092227511107922,-0.038630504161119,0.094633363187313,-0.096864342689514,0.050976842641830,-0.087170183658600,-0.098598815500736,0.043304201215506,0.066002085804939,0.179236352443695,-0.016295496374369) * MODEL2_texOff(vec2(1,-1));
res += mat4(-0.201210841536522,0.035690434277058,-0.200928896665573,0.095144428312778,0.038737531751394,0.288982301950455,-0.150241151452065,0.148405805230141,0.085267007350922,0.132294058799744,-0.060479447245598,-0.039577051997185,-0.142422348260880,-0.013202028349042,0.147893711924553,0.280225872993469) * MODEL2_texOff(vec2(1,0));
res += mat4(0.113246381282806,0.218809276819229,0.272320538759232,-0.044338263571262,-0.073010995984077,-0.107147328555584,0.059644311666489,0.052244596183300,-0.015198322944343,-0.082532458007336,-0.035606879740953,-0.012186860665679,0.286357283592224,0.065727613866329,-0.093843929469585,0.268358170986176) * MODEL2_texOff(vec2(1,1));
res += mat4(0.029072444885969,0.058523129671812,0.064008034765720,0.087875895202160,0.062898322939873,0.026045640930533,0.148952394723892,0.014870375394821,-0.031417220830917,0.138237178325653,-0.079335235059261,-0.080806210637093,0.031885940581560,0.058595936745405,0.058601256459951,0.029929835349321) * MODEL3_texOff(vec2(-1,-1));
res += mat4(-0.149323344230652,-0.008670910261571,-0.139395758509636,-0.005199515260756,-0.048945419490337,0.162374660372734,0.037672996520996,0.178974702954292,-0.154530853033066,0.046297188848257,-0.126615658402443,0.016358945518732,-0.034497708082199,-0.000222955975914,0.027498871088028,0.372376918792725) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.123527124524117,-0.036187350749969,0.087750740349293,-0.084177829325199,0.079848550260067,-0.124865047633648,0.010449932888150,0.006610244046897,-0.019473332911730,-0.002160622971132,-0.141976162791252,-0.086792618036270,-0.045798584818840,-0.032311804592609,-0.121842294931412,-0.022981014102697) * MODEL3_texOff(vec2(-1,1));
res += mat4(-0.048582982271910,0.100862659513950,-0.256274044513702,-0.200016096234322,0.095736794173717,0.008608722127974,-0.009489884600043,0.023024452850223,-0.205771446228027,0.243839234113693,0.238079905509949,0.071208544075489,-0.017680523917079,0.050306085497141,0.052749853581190,-0.195932731032372) * MODEL3_texOff(vec2(0,-1));
res += mat4(-0.283922821283340,-0.031314581632614,-0.051324624568224,-0.257660597562790,-0.030292475596070,-0.034636981785297,-0.163927510380745,-0.234629988670349,0.313163518905640,-0.404587894678116,-0.655424714088440,-0.192015230655670,0.089616470038891,-0.044888798147440,-0.188433378934860,-0.081734858453274) * MODEL3_texOff(vec2(0,0));
res += mat4(-0.030115107074380,-0.003044588258490,-0.102204218506813,0.039201535284519,-0.281541347503662,0.159562826156616,0.032371588051319,-0.069928020238876,-0.158076763153076,0.142573937773705,-0.089907728135586,-0.028130443766713,-0.127594113349915,-0.021266862750053,0.019434889778495,-0.276102185249329) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.185656473040581,0.052472278475761,0.042604669928551,0.116107337176800,0.296776235103607,-0.201823413372040,0.016808360815048,-0.142251655459404,0.069293744862080,0.178979426622391,0.031454153358936,-0.034374836832285,-0.120368175208569,0.002096352865919,-0.147443950176239,-0.033901896327734) * MODEL3_texOff(vec2(1,-1));
res += mat4(0.022617438808084,-0.080271974205971,-0.346885174512863,0.022068312391639,-0.073831960558891,-0.032521534711123,0.021381616592407,-0.077966406941414,0.105697318911552,-0.276688516139984,-0.210150554776192,-0.066261284053326,0.053079478442669,-0.076728858053684,0.214735612273216,-0.442567914724350) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.237448498606682,0.035609465092421,0.043448776006699,-0.174967467784882,-0.211745187640190,-0.031230418011546,0.004211478866637,-0.091357588768005,-0.098294883966446,-0.091466851532459,-0.030802059918642,-0.048353292047977,-0.062260918319225,-0.026532366871834,-0.138499513268471,-0.019663354381919) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.131415486335754,0.030357105657458,0.030620321631432,-0.031662888824940) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(-0.198523402214050,-0.199706822633743,0.015612882561982,-0.132838919758797);
res += mat4(0.153526872396469,0.037098694592714,0.046790286898613,-0.068338006734848,0.016924571245909,0.120973639190197,0.082589343190193,-0.063058227300644,0.158211633563042,0.077354572713375,-0.057695060968399,-0.180271595716476,-0.020717540755868,0.123721554875374,-0.015923323109746,0.062569163739681) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.179783076047897,-0.040876928716898,-0.100228033959866,-0.003528748871759,0.040155630558729,-0.013825055211782,0.065918356180191,0.000894078053534,0.024893574416637,-0.000878001679666,-0.046800766140223,0.197003304958344,-0.112161293625832,-0.133882075548172,0.160673633217812,-0.109223395586014) * MODEL1_texOff(vec2(-1,0));
res += mat4(0.037598289549351,0.086036577820778,0.067371226847172,-0.057131022214890,0.139673680067062,0.247766405344009,0.077560476958752,0.132156312465668,-0.103114806115627,-0.060886397957802,0.025572516024113,-0.004722683690488,0.115271233022213,0.113117247819901,-0.025095522403717,0.035373888909817) * MODEL1_texOff(vec2(-1,1));
res += mat4(-0.166496321558952,0.312494844198227,0.153483480215073,0.152234733104706,0.206820070743561,0.284117221832275,0.223053991794586,-0.001575593836606,0.018605910241604,0.287791281938553,0.086818836629391,0.277861982584000,0.119609452784061,-0.202930390834808,-0.111377902328968,-0.055466547608376) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.162010669708252,-0.047301195561886,0.246278181672096,-0.552165925502777,0.380666881799698,-0.248776257038116,-0.378765672445297,-0.067406646907330,-0.261994719505310,-0.373727232217789,0.329385310411453,-0.192686453461647,-0.199089705944061,0.042448922991753,-0.334000706672668,0.030061064288020) * MODEL1_texOff(vec2(0,0));
res += mat4(0.446991443634033,0.313174962997437,-0.171841025352478,0.190613493323326,-0.036646388471127,0.208605796098709,0.166280180215836,0.019918341189623,-0.165134310722351,-0.162465557456017,-0.076747447252274,-0.039784766733646,-0.006484336219728,0.022689538076520,-0.068151161074638,0.019760735332966) * MODEL1_texOff(vec2(0,1));
res += mat4(-0.017842575907707,0.139516636729240,-0.115694656968117,0.009072331711650,0.068349197506905,0.069530159235001,-0.038247138261795,-0.047822542488575,0.041093088686466,0.018553558737040,0.002432820620015,0.363521128892899,-0.028409481048584,0.023710839450359,0.025352602824569,-0.210937112569809) * MODEL1_texOff(vec2(1,-1));
res += mat4(0.006882162764668,0.048444952815771,-0.215612366795540,-0.137850895524025,0.144218996167183,0.023718113079667,-0.176360234618187,-0.194823965430260,0.020484987646341,-0.090955287218094,-0.166391745209694,-0.011509900912642,0.306069850921631,0.201510980725288,0.156795084476471,0.157517939805984) * MODEL1_texOff(vec2(1,0));
res += mat4(0.145843937993050,0.135416388511658,-0.150090411305428,0.048533737659454,-0.045555453747511,0.001303867553361,-0.007325317244977,0.089942909777164,0.078692376613617,-0.069968730211258,-0.071970172226429,0.047257483005524,-0.110769636929035,-0.162572845816612,-0.010653672739863,0.096725597977638) * MODEL1_texOff(vec2(1,1));
res += mat4(0.082586929202080,-0.011737608350813,0.042346540838480,0.156614214181900,-0.132219463586807,-0.073260694742203,-0.062275130301714,0.111676253378391,-0.071770817041397,0.312464207410812,-0.011426193639636,0.140951409935951,0.010868234559894,0.139271229505539,0.005583952181041,0.009392702020705) * MODEL2_texOff(vec2(-1,-1));
res += mat4(0.077518247067928,0.104544892907143,-0.086679771542549,-0.057435855269432,-0.066198959946632,0.073223307728767,0.026192270219326,0.038676377385855,0.359223663806915,-0.306882649660110,-0.000182649906492,-0.229985043406487,-0.004824721720070,-0.019485367462039,-0.017724081873894,-0.167155340313911) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.121730960905552,-0.042365513741970,0.067717395722866,-0.055307090282440,0.000276344857411,0.079978309571743,-0.021159177646041,-0.039169300347567,0.029097748920321,0.275664269924164,0.089252866804600,0.027910098433495,-0.000787227298133,0.062770016491413,0.041154801845551,-0.097752772271633) * MODEL2_texOff(vec2(-1,1));
res += mat4(0.198236912488937,0.270133286714554,0.475597113370895,0.486972212791443,0.591192722320557,-0.127121120691299,-0.161231413483620,0.328464567661285,0.003135026199743,-0.132895186543465,0.005237410310656,0.153676956892014,0.050687931478024,0.116461537778378,-0.019922230392694,-0.083539001643658) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.345354199409485,-0.065231740474701,-0.227629661560059,-0.137219667434692,-0.261112183332443,-0.363433212041855,-0.011154034174979,-0.253620535135269,-0.244628667831421,0.097696356475353,0.025357371196151,-0.278769761323929,0.177168950438499,-0.238814324140549,0.118998780846596,-0.122307755053043) * MODEL2_texOff(vec2(0,0));
res += mat4(-0.254433095455170,-0.061199456453323,0.159624040126801,-0.185565814375877,-0.124016650021076,0.424701184034348,0.126425161957741,0.183027550578117,-0.058084592223167,-0.175016954541206,0.008243167772889,0.030805489048362,-0.338661193847656,0.005182279739529,0.033289004117250,-0.357736527919769) * MODEL2_texOff(vec2(0,1));
res += mat4(0.106617532670498,0.099054001271725,0.140963077545166,0.124456346035004,0.199208408594131,0.073967799544334,-0.032396256923676,-0.108643360435963,0.025407548993826,-0.031205791980028,0.032908953726292,-0.062248963862658,0.047277972102165,-0.047366790473461,-0.033640421926975,-0.019090851768851) * MODEL2_texOff(vec2(1,-1));
res += mat4(-0.168942749500275,-0.108320668339729,-0.063015334308147,0.128886565566063,0.108773514628410,0.106829017400742,-0.004278433043510,-0.084903821349144,-0.101412259042263,-0.108588270843029,-0.009570253081620,0.035595104098320,-0.021381264552474,0.032840259373188,-0.111789658665657,0.003088264726102) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.032776042819023,-0.125315397977829,-0.047408409416676,0.019471930339932,-0.110518015921116,-0.189301207661629,0.064047962427139,0.214743211865425,0.024697698652744,-0.059983719140291,-0.037201266735792,-0.028423774987459,-0.017083713784814,-0.128642171621323,-0.036137480288744,0.025295855477452) * MODEL2_texOff(vec2(1,1));
res += mat4(-0.093177661299706,-0.133958250284195,0.047006674110889,-0.158087283372879,0.041123621165752,0.027502726763487,0.065612673759460,-0.144570440053940,0.042692463845015,-0.055049702525139,-0.002549610566348,-0.208840772509575,-0.067966371774673,0.049818929284811,0.024007659405470,0.027742212638259) * MODEL3_texOff(vec2(-1,-1));
res += mat4(0.055836666375399,-0.000199353438802,-0.056215092539787,0.290905207395554,-0.248637914657593,-0.276755809783936,0.170917168259621,0.134488850831985,0.129134669899940,0.195265561342239,-0.035781905055046,-0.054763216525316,0.016924222931266,-0.121990412473679,0.119343385100365,-0.026415234431624) * MODEL3_texOff(vec2(-1,0));
res += mat4(-0.136057540774345,0.016061756759882,0.016097007319331,-0.119860485196114,0.075013533234596,-0.320852816104889,-0.020375249907374,0.275476425886154,-0.033576730638742,0.092434637248516,-0.024227906018496,-0.176724642515182,0.053971331566572,-0.005135609302670,0.110436186194420,-0.056867528706789) * MODEL3_texOff(vec2(-1,1));
res += mat4(-0.375006377696991,0.137376099824905,0.124070100486279,-0.105942770838737,-0.329763472080231,0.308133870363235,0.106422588229179,-0.098273538053036,0.157005026936531,0.188715234398842,-0.018741102889180,-0.066985137760639,-0.109577678143978,-0.060054793953896,-0.007719144690782,0.020465828478336) * MODEL3_texOff(vec2(0,-1));
res += mat4(0.187320709228516,-0.376925319433212,-0.033311564475298,-0.261821389198303,-0.542155921459198,-0.071733422577381,-0.172424435615540,-0.435934394598007,0.418991565704346,-0.005422912538052,-0.062622278928757,-0.004983244463801,-0.000981402117759,0.367230862379074,-0.206526204943657,-0.228543981909752) * MODEL3_texOff(vec2(0,0));
res += mat4(-0.213968873023987,-0.156135499477386,0.175199195742607,-0.135342836380005,0.437227725982666,-0.190229475498199,-0.134535998106003,0.205376878380775,-0.177323445677757,0.127196729183197,0.157024323940277,-0.216060265898705,0.182485684752464,-0.001775335287675,-0.278138250112534,0.131207212805748) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.087383970618248,-0.082495823502541,-0.096207648515701,-0.134347334504128,-0.344156473875046,-0.256496161222458,-0.021753413602710,0.111183047294617,0.087990857660770,0.093291759490967,0.071484811604023,-0.051019560545683,-0.018721496686339,0.001277823233977,-0.032668128609657,-0.077381215989590) * MODEL3_texOff(vec2(1,-1));
res += mat4(0.040407028049231,0.075511537492275,-0.180688202381134,-0.073242515325546,-0.253065764904022,-0.141031295061111,0.182686269283295,0.077539429068565,0.039150550961494,0.144715264439583,-0.247616589069366,-0.122049674391747,0.075192980468273,0.013161263428628,0.318069607019424,0.116127967834473) * MODEL3_texOff(vec2(1,0));
res += mat4(0.086133107542992,-0.035396538674831,-0.046604819595814,-0.015842013061047,0.120983488857746,0.056677401065826,-0.030260233208537,-0.077296853065491,-0.042539983987808,-0.050352424383163,-0.005693458486348,0.040422748774290,-0.082035645842552,0.124410092830658,0.106689862906933,-0.198133394122124) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.064776189625263,0.041078351438046,1.017757654190063,0.056476294994354) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL1
//!BIND MODEL2
//!BIND MODEL3
//!SAVE MODEL6
//!DESC [AiUpscale_Fast_4x_Photo_RT] mapping 4_3

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(-0.033499278128147,-0.109900839626789,0.035686891525984,-0.287853956222534);
res += mat4(-0.103192977607250,-0.050950434058905,0.121202617883682,-0.007443279959261,-0.008549803867936,0.140945255756378,-0.033768087625504,-0.064554572105408,-0.076790682971478,0.105205558240414,-0.027537595480680,0.008010643534362,-0.007936793379486,-0.075198732316494,0.117399238049984,-0.036844290792942) * MODEL1_texOff(vec2(-1,-1));
res += mat4(-0.130197197198868,-0.055253908038139,0.261268109083176,-0.007779030594975,0.160001099109650,-0.024650443345308,-0.370847225189209,-0.065314680337906,0.027231302112341,0.077398471534252,-0.076973557472229,-0.017514208331704,-0.109656758606434,-0.029363766312599,0.467182487249374,0.032910738140345) * MODEL1_texOff(vec2(-1,0));
res += mat4(0.035230502486229,-0.033338755369186,-0.050044961273670,-0.001517555443570,0.009702152572572,0.026874313130975,-0.058903705328703,0.025581620633602,0.057251367717981,-0.067491531372070,-0.047009259462357,-0.015325910411775,0.047066699713469,-0.048019625246525,0.038458701223135,-0.000925801286940) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.137252420186996,-0.509639620780945,-0.121146999299526,-0.083303056657314,-0.146842375397682,0.372567385435104,-0.072680324316025,0.064782269299030,0.079795271158218,0.149427101016045,-0.243290111422539,-0.044256392866373,0.342200130224228,-0.036854505538940,0.027808360755444,0.138698548078537) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.018708687275648,0.628271460533142,-0.244283989071846,-0.160108029842377,-0.232521533966064,-0.128887131810188,0.434089422225952,0.328023880720139,-0.243641749024391,0.359646648168564,0.097943730652332,0.074061416089535,0.110981702804565,0.115198232233524,0.645446360111237,0.291135519742966) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.076176300644875,-0.387235969305038,-0.019432419911027,-0.170463234186172,-0.053733170032501,0.275446116924286,0.019111910834908,-0.049764085561037,-0.059706397354603,-0.193868070840836,-0.113607540726662,-0.138540536165237,0.201176226139069,-0.285831689834595,0.054659407585859,0.361367404460907) * MODEL1_texOff(vec2(0,1));
res += mat4(-0.222181722521782,-0.007251734379679,0.005937681999058,-0.085733443498611,-0.037737697362900,-0.089692793786526,-0.018599793314934,-0.074748627841473,0.033409480005503,0.042250711470842,-0.016613043844700,0.013809295371175,0.223748728632927,0.017349984496832,-0.009837715886533,-0.017092352733016) * MODEL1_texOff(vec2(1,-1));
res += mat4(-0.246375218033791,0.016471128910780,0.242307424545288,0.227681592106819,0.143121987581253,0.008190583437681,-0.259456247091293,-0.213199332356453,-0.055259969085455,0.159454613924026,-0.173050031065941,-0.116473965346813,0.443394452333450,-0.044681668281555,-0.383785098791122,-0.395655333995819) * MODEL1_texOff(vec2(1,0));
res += mat4(-0.283361256122589,-0.109293095767498,0.051815401762724,0.090094998478889,-0.110679730772972,0.023007106035948,-0.168430343270302,-0.152109876275063,0.024069994688034,0.018510360270739,0.068827137351036,0.040572293102741,0.004691359121352,0.034856885671616,-0.027889085933566,-0.058242771774530) * MODEL1_texOff(vec2(1,1));
res += mat4(0.074639305472374,0.108113318681717,-0.056460525840521,-0.079712018370628,-0.101189285516739,-0.018950739875436,-0.000623771396931,-0.037439431995153,-0.007488838862628,0.114985764026642,0.050143171101809,-0.076408669352531,-0.044608462601900,0.144181177020073,0.043834026902914,-0.065390400588512) * MODEL2_texOff(vec2(-1,-1));
res += mat4(-0.004912011791021,-0.050528727471828,0.010503662750125,-0.069747224450111,-0.219283476471901,-0.082443296909332,0.456156402826309,0.061838358640671,-0.137764424085617,-0.042527709156275,0.301949471235275,-0.045596636831760,-0.150980249047279,-0.021403340622783,0.191540107131004,0.051096968352795) * MODEL2_texOff(vec2(-1,0));
res += mat4(-0.015560871921480,0.302709341049194,-0.087723523378372,-0.024139707908034,-0.105071470141411,0.056844547390938,0.032081592828035,0.032138954848051,-0.018309511244297,0.050711303949356,0.083939984440804,0.062661439180374,-0.073049157857895,-0.139486163854599,0.171401664614677,0.037917468696833) * MODEL2_texOff(vec2(-1,1));
res += mat4(-0.085803829133511,0.413241714239120,-0.023962860926986,0.036991082131863,0.052843339741230,-0.055475585162640,0.069993622601032,-0.198400422930717,0.233027204871178,0.332205355167389,-0.066200233995914,-0.138345196843147,0.123926736414433,0.275844484567642,-0.118659526109695,-0.131356924772263) * MODEL2_texOff(vec2(0,-1));
res += mat4(0.028484700247645,-0.196743130683899,0.050046749413013,0.044076707214117,0.383613467216492,-0.038998432457447,-0.372129917144775,-0.678043246269226,0.514141917228699,-0.010182812809944,-0.318072378635406,-0.261342287063599,-0.054745826870203,0.141792774200439,0.203984797000885,-0.216573789715767) * MODEL2_texOff(vec2(0,0));
res += mat4(0.169052839279175,0.346801072359085,-0.026636835187674,0.040602244436741,-0.039002839475870,-0.065817601978779,0.062561616301537,-0.285260260105133,0.143405675888062,0.083104938268661,0.049459997564554,-0.114792525768280,0.113512232899666,-0.130273386836052,-0.101621240377426,-0.163266450166702) * MODEL2_texOff(vec2(0,1));
res += mat4(-0.031349424272776,-0.097707398235798,0.027999509125948,-0.025299236178398,-0.016209177672863,-0.050545193254948,0.113757975399494,0.197523176670074,-0.317430406808853,0.044885504990816,0.128144279122353,0.143090322613716,-0.173857554793358,0.165945872664452,-0.091024786233902,-0.219593748450279) * MODEL2_texOff(vec2(1,-1));
res += mat4(0.199043869972229,-0.042537633329630,-0.052823305130005,-0.054763801395893,0.346882909536362,0.010705251246691,0.256496340036392,0.743066549301147,-0.189500734210014,0.103290930390358,0.088536784052849,-0.039951723068953,0.247946500778198,0.160406216979027,-0.460439532995224,-0.640050053596497) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.150289356708527,0.156198322772980,-0.050639089196920,-0.053109638392925,0.118385128676891,-0.075296118855476,0.131615623831749,0.206979200243950,-0.078599348664284,0.066008284687996,0.017492640763521,-0.043664854019880,-0.170746073126793,0.180492863059044,-0.154595002532005,-0.266734391450882) * MODEL2_texOff(vec2(1,1));
res += mat4(0.099829606711864,-0.320761054754257,-0.257581353187561,-0.024072222411633,-0.198547333478928,0.060087900608778,0.205040499567986,0.100718021392822,0.023400764912367,0.154316812753677,-0.040260825306177,0.017262935638428,0.188942044973373,0.070982910692692,-0.047355048358440,0.029618304222822) * MODEL3_texOff(vec2(-1,-1));
res += mat4(0.071060404181480,-0.013510924763978,-0.089707516133785,-0.011030131950974,0.264255136251450,-0.127316921949387,-0.101470410823822,0.070830471813679,-0.129966869950294,-0.115375205874443,0.009779319167137,0.011014776304364,0.245287835597992,-0.028260987251997,-0.435855656862259,0.035649884492159) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.000388872053009,-0.123610921204090,0.116809740662575,0.069381840527058,0.159434407949448,0.090750940144062,-0.030534472316504,0.016490262001753,-0.017626032233238,0.103157438337803,-0.014711514115334,0.052189607173204,0.032288026064634,-0.032471943646669,-0.079201810061932,0.043580900877714) * MODEL3_texOff(vec2(-1,1));
res += mat4(-0.205867871642113,-0.092037424445152,0.124563090503216,0.107917778193951,0.164861038327217,-0.427903711795807,-0.284274637699127,-0.266922444105148,0.039734728634357,0.544635474681854,0.096335276961327,-0.048506427556276,-0.106985680758953,0.040039468556643,-0.038278944790363,0.037285793572664) * MODEL3_texOff(vec2(0,-1));
res += mat4(-0.207505211234093,-0.393793106079102,-0.041941002011299,0.077587991952896,-0.417751938104630,-0.223876595497131,0.097348332405090,0.009304842911661,0.252350002527237,-0.424144774675369,-0.154970675706863,-0.041810683906078,-0.417782038450241,0.042774289846420,-0.139959454536438,0.490535140037537) * MODEL3_texOff(vec2(0,0));
res += mat4(-0.016172187402844,0.159728780388832,-0.203212976455688,-0.242620378732681,-0.202542275190353,0.153284326195717,0.014413656666875,0.070235989987850,-0.026803486049175,0.307739853858948,-0.003624946577474,-0.058333940804005,-0.151241093873978,0.031015358865261,-0.041166596114635,-0.046789351850748) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.011610045097768,0.215244695544243,-0.207252800464630,-0.208756595849991,-0.277076244354248,-0.142506942152977,0.155088618397713,0.085972703993320,-0.134962975978851,0.120302185416222,-0.078577548265457,-0.097638793289661,-0.378765970468521,-0.032796077430248,0.038071576505899,-0.087925866246223) * MODEL3_texOff(vec2(1,-1));
res += mat4(-0.228288888931274,-0.430765390396118,-0.104408949613571,-0.145558461546898,-0.045322272926569,-0.016646867617965,-0.080139890313148,-0.101059168577194,-0.115634903311729,-0.087570391595364,0.095667637884617,0.138233110308647,-0.474351137876511,0.030524676665664,0.267675697803497,0.330867081880569) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.165681168437004,0.103204436600208,0.195776924490929,0.026254815980792,0.143611595034599,-0.020945051684976,-0.098997503519058,-0.061826404184103,0.060270197689533,-0.097985006868839,-0.058590486645699,0.010032539255917,-0.095932029187679,0.022917786613107,-0.073143675923347,-0.071358419954777) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.002374108647928,0.213781461119652,0.259110122919083,0.006704105995595) * min(res, vec4(0.0));
#elif (SHARP == 1)
vec4 res = vec4(-0.182868972420692,-0.100015297532082,-0.151462122797966,-0.233923211693764);
res += mat4(-0.102196507155895,0.008013999089599,-0.303096383810043,0.011233902536333,0.127661243081093,0.074286215007305,0.199129983782768,0.021524688228965,0.031552121043205,0.024122241884470,0.098073117434978,0.045620664954185,0.125608876347542,0.044751640409231,0.182966664433479,0.067386947572231) * MODEL1_texOff(vec2(-1,-1));
res += mat4(0.041641417890787,-0.147509604692459,-0.554293870925903,-0.018302550539374,0.201242640614510,-0.040362186729908,0.484697848558426,0.116384796798229,0.042016189545393,-0.256883978843689,0.055292185395956,-0.111300058662891,0.255702942609787,0.014440468512475,0.569190323352814,0.226576611399651) * MODEL1_texOff(vec2(-1,0));
res += mat4(0.049285799264908,-0.027416950091720,-0.177346155047417,-0.010596723295748,0.023503307253122,0.120254799723625,0.003558640601113,0.049182429909706,0.004200087394565,0.194295689463615,0.195574462413788,0.059150338172913,-0.011999041773379,-0.002914926270023,0.134783789515495,0.033642075955868) * MODEL1_texOff(vec2(-1,1));
res += mat4(0.100887641310692,0.151122987270355,0.131461337208748,-0.033397555351257,-0.017478408291936,0.135045215487480,0.078389145433903,-0.095510341227055,0.092739030718803,0.205375611782074,0.312645554542542,0.175668895244598,-0.148132234811783,0.002694833325222,0.118971198797226,-0.053935497999191) * MODEL1_texOff(vec2(0,-1));
res += mat4(0.207874134182930,-0.111908085644245,0.006403563544154,-0.073960550129414,-0.331003338098526,-0.234788775444031,-0.118452101945877,-0.351059615612030,0.142691865563393,-0.153435900807381,0.264353752136230,-0.025147635489702,-0.521269738674164,-0.108233533799648,0.316335231065750,-0.418879508972168) * MODEL1_texOff(vec2(0,0));
res += mat4(-0.045292213559151,-0.461984902620316,-0.060397490859032,-0.165708169341087,-0.007764393463731,0.204097062349319,0.118579305708408,-0.206939235329628,0.062184751033783,-0.019037710502744,0.061375651508570,0.069117374718189,-0.202766090631485,0.190864741802216,0.043248355388641,-0.090738594532013) * MODEL1_texOff(vec2(0,1));
res += mat4(-0.093172155320644,0.217388644814491,0.142427176237106,0.051647681742907,0.058242779225111,-0.020686738193035,-0.165597945451736,0.040598459541798,0.176912441849709,0.061491634696722,-0.127589553594589,0.029409188777208,0.181343153119087,-0.125915110111237,-0.075321599841118,0.123241677880287) * MODEL1_texOff(vec2(1,-1));
res += mat4(-0.031801331788301,-0.206379741430283,0.004349923692644,0.212017834186554,0.084753513336182,-0.068496346473694,-0.359094858169556,0.095184035599232,0.200880751013756,0.146269470453262,-0.101871870458126,0.296222627162933,0.761988818645477,0.132339313626289,-0.171726554632187,0.624092996120453) * MODEL1_texOff(vec2(1,0));
res += mat4(0.175260856747627,-0.243101179599762,0.080465145409107,0.146938338875771,0.146131262183189,0.166281193494797,-0.232543990015984,0.131415903568268,0.009451567195356,0.048566132783890,-0.088409639894962,0.031631451100111,0.121784478425980,0.043943043798208,-0.002366015221924,0.185139030218124) * MODEL1_texOff(vec2(1,1));
res += mat4(-0.048552598804235,0.167963281273842,-0.049781095236540,0.005924254655838,0.005605804733932,-0.138618335127831,0.113689228892326,-0.112667232751846,0.077864877879620,0.116079956293106,-0.199844345450401,0.100140973925591,0.097687311470509,0.008039426989853,0.021056957542896,0.023892499506474) * MODEL2_texOff(vec2(-1,-1));
res += mat4(0.058742504566908,-0.015543815679848,0.164875939488411,0.049639724195004,0.074993669986725,-0.008741044439375,-0.150090679526329,-0.056033462285995,0.346505254507065,-0.105545572936535,0.403287768363953,0.343214303255081,0.071774229407310,-0.004060082137585,-0.161887615919113,0.216508194804192) * MODEL2_texOff(vec2(-1,0));
res += mat4(0.006340499967337,-0.219342887401581,0.022258643060923,0.081861101090908,-0.030333342030644,0.001048164325766,-0.163287386298180,-0.078409694135189,0.144331440329552,-0.076553307473660,-0.013423118740320,0.207742050290108,0.015923958271742,-0.195091769099236,0.062060292810202,0.073205046355724) * MODEL2_texOff(vec2(-1,1));
res += mat4(0.247276782989502,0.162193119525909,-0.004853666294366,0.048312261700630,-0.216326385736465,-0.485119611024857,-0.282676666975021,-0.075678296387196,0.007470624055713,-0.145803824067116,0.096788279712200,-0.149939507246017,-0.018910344690084,0.078877799212933,0.163996577262878,-0.013266251422465) * MODEL2_texOff(vec2(0,-1));
res += mat4(-0.138508051633835,0.343952059745789,-0.080657102167606,0.001968543045223,-0.264659136533737,0.262477785348892,0.106000415980816,-0.137682557106018,-0.377069473266602,0.247215315699577,0.087086878716946,-1.091432929039001,-0.167590156197548,-0.281947016716003,0.173035740852356,-0.174948871135712) * MODEL2_texOff(vec2(0,0));
res += mat4(0.046720881015062,0.172550261020660,-0.090003557503223,-0.042153727263212,-0.246469691395760,0.633432269096375,0.114694207906723,-0.042926643043756,0.170504882931709,-0.227660804986954,0.026245631277561,-0.113104447722435,0.112973168492317,-0.233930930495262,0.036540847271681,0.112705133855343) * MODEL2_texOff(vec2(0,1));
res += mat4(-0.233602419495583,-0.005245636682957,-0.053031917661428,-0.089180551469326,0.187398493289948,-0.130740508437157,0.190474361181259,0.089181080460548,0.019561652094126,-0.123651593923569,-0.037792719900608,-0.047766987234354,-0.011033730581403,-0.026513421908021,-0.063271127641201,0.069284111261368) * MODEL2_texOff(vec2(1,-1));
res += mat4(0.060439653694630,0.154823005199432,-0.012047095224261,-0.037112630903721,-0.203051373362541,-0.040528081357479,-0.036229468882084,0.023113466799259,0.094985648989677,0.147803515195847,-0.097124852240086,-0.122314848005772,-0.238396972417831,0.114408634603024,-0.148968055844307,-0.029520807787776) * MODEL2_texOff(vec2(1,0));
res += mat4(-0.005999751389027,0.123462088406086,0.078613504767418,0.035623464733362,-0.094419315457344,0.181498944759369,-0.045948807150126,-0.070155479013920,-0.012677229940891,-0.121042609214783,-0.049454450607300,-0.068774282932281,-0.245307341217995,0.107518054544926,-0.062315080314875,-0.147342279553413) * MODEL2_texOff(vec2(1,1));
res += mat4(0.037496700882912,0.014168510213494,-0.208721116185188,0.139378502964973,0.109035447239876,0.128914028406143,0.013388649560511,0.111831329762936,0.169249951839447,-0.105001948773861,-0.109046474099159,0.031561426818371,-0.145287454128265,0.044061608612537,0.076521672308445,-0.047916375100613) * MODEL3_texOff(vec2(-1,-1));
res += mat4(0.250212043523788,0.181495442986488,-0.147910609841347,0.057202532887459,0.086347088217735,-0.001434748410247,-0.188730940222740,0.100890979170799,-0.093057937920094,-0.192915812134743,-0.337241441011429,0.003358456538990,0.020976025611162,-0.034736484289169,0.714866578578949,0.191030696034431) * MODEL3_texOff(vec2(-1,0));
res += mat4(0.012239086441696,-0.085337147116661,0.048393394798040,0.010959779843688,0.149306878447533,0.045180540531874,-0.014833233319223,-0.008579794317484,-0.076870247721672,-0.076612874865532,-0.190062046051025,-0.127981126308441,-0.193057760596275,-0.074988275766373,0.284530818462372,0.025111302733421) * MODEL3_texOff(vec2(-1,1));
res += mat4(0.169945165514946,0.240210965275764,0.194335594773293,-0.166202276945114,-0.161274343729019,0.306029886007309,0.018900984898210,-0.035058282315731,-0.137974947690964,0.169208824634552,-0.000397991097998,-0.051104594022036,-0.057761855423450,-0.184338897466660,-0.141091585159302,-0.039061065763235) * MODEL3_texOff(vec2(0,-1));
res += mat4(0.264741629362106,-0.560758411884308,0.198759108781815,0.041105467826128,-0.155415132641792,-0.182264268398285,-0.164626389741898,-0.143225505948067,-0.027195949107409,-0.175581619143486,0.088360659778118,-0.016005668789148,-0.241323888301849,0.171146795153618,-0.096465043723583,0.068982660770416) * MODEL3_texOff(vec2(0,0));
res += mat4(0.173655390739441,-0.075806736946106,0.059372711926699,0.121229402720928,-0.050187665969133,-0.652755498886108,-0.053376678377390,-0.113647423684597,-0.057237371802330,-0.033825598657131,0.039298929274082,-0.030358662828803,-0.153783723711967,-0.195285558700562,-0.087514311075211,0.008088527247310) * MODEL3_texOff(vec2(0,1));
res += mat4(-0.062443807721138,0.052458237856627,-0.058651041239500,0.040976643562317,-0.036500494927168,-0.015017624013126,-0.046643305569887,-0.021135292947292,-0.155814483761787,0.041060443967581,-0.094165787100792,-0.105065599083900,0.032683350145817,-0.205160647630692,-0.017581107094884,-0.094285368919373) * MODEL3_texOff(vec2(1,-1));
res += mat4(-0.181165009737015,-0.109697416424751,-0.159586057066917,-0.083531208336353,0.097120434045792,0.153715148568153,0.227401077747345,0.050658453255892,-0.213089630007744,-0.183973282575607,-0.210980579257011,-0.038288418203592,0.048542480915785,0.239016950130463,0.070590510964394,-0.254606992006302) * MODEL3_texOff(vec2(1,0));
res += mat4(-0.028325209394097,-0.037013303488493,-0.142266616225243,-0.023181319236755,0.075474865734577,-0.239919722080231,0.139243111014366,0.116650357842445,-0.126283869147301,0.062646821141243,-0.128160625696182,-0.129777431488037,-0.162443742156029,-0.265731483697891,-0.025451315566897,-0.271245151758194) * MODEL3_texOff(vec2(1,1));
res = max(res, vec4(0.0)) + vec4(0.034319728612900,0.045698352158070,0.083828672766685,0.029636463150382) * min(res, vec4(0.0));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL4
//!BIND MODEL5
//!BIND MODEL6
//!SAVE SUBCONV1
//!DESC [AiUpscale_Fast_4x_Photo_RT] sup-pixel convolution 1

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.001087737618946,0.000186694029253,-0.000830084551126,0.000086282336270);
res += mat4(-0.007419803645462,-0.009816339239478,-0.005396097432822,-0.001737589598633,0.013113760389388,0.010718444362283,-0.000638500670902,-0.000291776290396,-0.036277461796999,0.009201761335135,0.018472885712981,0.004568593576550,-0.006506371777505,-0.005949473008513,-0.004421413410455,-0.001878910115920) * MODEL4_texOff(vec2(-1,-1));
res += mat4(0.003949438221753,0.009571563452482,0.007911955006421,0.002026887377724,0.019582802429795,-0.003602670039982,-0.025548689067364,-0.008125280961394,0.017564846202731,0.035468414425850,0.003847816726193,-0.048878356814384,-0.006455219350755,-0.004780913237482,-0.002237992361188,-0.003583108540624) * MODEL4_texOff(vec2(-1,0));
res += mat4(-0.003552235197276,-0.008476533927023,-0.013317692093551,-0.008957823738456,-0.003717079758644,-0.006300619337708,-0.003346021985635,0.010473067872226,-0.004628824070096,-0.001584012643434,0.000506438082084,0.003484008368105,-0.000209432881093,-0.003025599522516,-0.006517355795950,-0.007439374923706) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.002219299087301,-0.010158844292164,-0.010044462047517,-0.004929337184876,-0.026127539575100,-0.001200540573336,0.009474869817495,0.009387798607349,0.018185082823038,0.004228054545820,-0.004178388509899,-0.006684269290417,-0.005229152739048,-0.000035766111978,-0.000317326252116,-0.002495309105143) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.016229776665568,0.027491580694914,0.028692988678813,0.021033296361566,0.021435406059027,0.042207766324282,0.004055195022374,-0.033711601048708,-0.046702794730663,-0.021264467388391,0.029709866270423,0.034944448620081,-0.059051528573036,-0.068091616034508,-0.055642656981945,-0.030027274042368) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.002401692792773,-0.006538368761539,-0.010258979164064,-0.002779557136819,-0.000032845608075,-0.004369670990855,-0.018715864047408,-0.013852732256055,0.001587359467521,0.009101754985750,0.015762446448207,-0.010729582048953,-0.005538503173739,-0.007216905243695,-0.016942869871855,-0.037655968219042) * MODEL4_texOff(vec2(0,1));
res += mat4(-0.005835189484060,-0.004806078039110,-0.002369433641434,0.000028690374165,-0.000562018831261,0.002944733249024,0.002030279953033,-0.000110641769425,-0.009413504973054,-0.006011425983161,-0.002908294089139,0.002074453979731,-0.003015852533281,0.001614405424334,-0.002115374663845,-0.005270804744214) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.006410576403141,-0.006806455552578,-0.007671386469156,-0.006895682774484,0.002065887209028,0.000012410523595,-0.005790349561721,-0.004510146100074,-0.001720429398119,0.011422862298787,0.008925293572247,-0.007348298095167,-0.043969959020615,-0.047068338841200,-0.033184159547091,-0.012378509156406) * MODEL4_texOff(vec2(1,0));
res += mat4(0.000853471341543,-0.000648628221825,-0.003747367532924,-0.005910356529057,0.006072271149606,0.003652553306893,-0.002530632307753,-0.003538499120623,-0.001796379103325,0.001467521185987,0.001518306788057,-0.004194512963295,0.000730132276658,-0.004557366948575,-0.014288912527263,-0.028163921087980) * MODEL4_texOff(vec2(1,1));
res += mat4(-0.021836316213012,0.003360699396580,0.014568883925676,0.006867042277008,0.001160439918749,-0.022420160472393,-0.007186291273683,0.002384656574577,0.011093906126916,-0.004765908233821,-0.003796220524237,0.001004216144793,-0.017351794987917,-0.002867276081815,0.006243193522096,0.009144762530923) * MODEL5_texOff(vec2(-1,-1));
res += mat4(0.023268964141607,0.033880107104778,0.006380883976817,-0.025804340839386,-0.029913594946265,-0.018599515780807,0.025031885132194,0.039008688181639,-0.031414709985256,-0.025707812979817,0.010886915028095,0.027746204286814,0.025426488369703,0.012119799852371,-0.014965789392591,-0.029492009431124) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.004438295960426,-0.006261741276830,-0.009389312937856,0.000665406521875,0.005912566091865,0.006939804181457,0.001093379221857,-0.014642888680100,0.000098615644674,0.002386574866250,0.005140989087522,-0.007136355154216,-0.002965551801026,-0.000886230496690,0.006778963841498,0.017111603170633) * MODEL5_texOff(vec2(-1,1));
res += mat4(0.022472793236375,0.012849762104452,-0.003433782141656,-0.003915297798812,0.010565913282335,-0.000572371238377,-0.003841933328658,-0.001439045998268,-0.035860437899828,-0.004279397893697,0.011955051682889,0.010556756518781,0.006339459214360,-0.011539335362613,-0.011589081026614,-0.003171721240506) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.019574835896492,-0.022007273510098,-0.035675857216120,0.000144293109770,0.037775456905365,-0.022410189732909,-0.039827633649111,-0.002144803991541,0.029759725555778,0.028588285669684,-0.013179648667574,-0.050984766334295,0.019810790196061,0.036811787635088,0.045352376997471,0.030945772305131) * MODEL5_texOff(vec2(0,0));
res += mat4(-0.006995668169111,-0.012146402150393,-0.000031599116483,0.022670004516840,-0.009565047919750,-0.011742067523301,0.003386707510799,0.039258599281311,-0.001335495850071,-0.001206078915857,-0.003024775302038,0.007537700235844,0.002230138052255,-0.002019245643169,-0.004886875394732,0.003262964775786) * MODEL5_texOff(vec2(0,1));
res += mat4(-0.001652342732996,-0.004415110219270,-0.003182518761605,-0.001421589404345,0.004693776369095,-0.000038290130760,-0.000011174649444,-0.003130519296974,0.000144305391586,0.002109577413648,0.002321604639292,-0.000585947535001,0.006989228073508,0.004073210991919,0.000619469967205,0.000577460858040) * MODEL5_texOff(vec2(1,-1));
res += mat4(0.001680657151155,-0.001833227346651,0.000114628259325,0.000322905689245,-0.004307285416871,-0.007841185666621,0.002583712805063,0.009477554820478,-0.001820168923587,0.003347036661580,0.005450383294374,0.001213536714204,-0.006485426798463,-0.005983482580632,0.000642631144729,0.006082311272621) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.005680281668901,-0.001104051596485,0.005410637706518,0.006058333907276,-0.002110387198627,-0.005351126194000,-0.002109921304509,0.003378143534064,-0.001441881177016,-0.005489738192409,-0.004387834575027,-0.001892534783110,-0.000630104623269,-0.001429405878298,-0.000948258035351,-0.003021233016625) * MODEL5_texOff(vec2(1,1));
res += mat4(0.012506943196058,0.000881926331203,-0.008883115835488,-0.010531133040786,0.010991829447448,-0.001307926373556,-0.008331253193319,-0.005594066809863,0.007896239869297,0.002851897850633,0.001041008275934,0.000619490048848,0.018623040989041,0.009802176617086,0.007147420663387,0.006401473656297) * MODEL6_texOff(vec2(-1,-1));
res += mat4(-0.047740560024977,-0.028181837871671,0.001319683389738,0.018473604694009,-0.003888416802511,-0.008147105574608,-0.002930915448815,0.010625454597175,0.022684307768941,0.023970050737262,0.019414838403463,0.014630263671279,0.053686484694481,0.065954059362411,0.059480749070644,0.041390549391508) * MODEL6_texOff(vec2(-1,0));
res += mat4(0.006020671222359,-0.002602902241051,-0.022039175033569,-0.040219120681286,0.004612165968865,0.003586635226384,0.000232912876527,-0.001775765325874,-0.002851334633306,-0.001156794372946,0.003668779041618,0.012102431617677,0.002588036470115,0.004936141427606,0.011179438792169,0.026347659528255) * MODEL6_texOff(vec2(-1,1));
res += mat4(0.011144888587296,0.001585469464771,-0.003496370278299,-0.003190091345459,0.020103385671973,-0.005526774097234,-0.016168033704162,-0.013518998399377,-0.018075885251164,-0.004133276175708,0.002610442927107,0.002830789657310,-0.007920097559690,-0.009052584879100,-0.004340249579400,0.001076864427887) * MODEL6_texOff(vec2(0,-1));
res += mat4(0.012506056576967,0.021771587431431,0.027577742934227,0.024236423894763,-0.045777849853039,-0.012272462248802,0.030491407960653,0.041767634451389,-0.029414588585496,-0.045113284140825,-0.049946062266827,-0.039908610284328,0.013917971402407,0.021800026297569,0.014382736757398,-0.002506794640794) * MODEL6_texOff(vec2(0,0));
res += mat4(0.005093409679830,0.003984804265201,0.002615093952045,0.006408867426217,0.012444778345525,0.015868039801717,0.002907322952524,-0.031010782346129,0.002125538419932,0.002349550137296,0.000392929126974,-0.008995768614113,-0.003084246534854,-0.005771381314844,-0.004020385444164,0.004006163217127) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.008108394220471,-0.004345175810158,-0.000672477704939,0.000946627347730,-0.001361091737635,0.000388529646443,0.001417668536305,0.002952970331535,0.009184263646603,0.004671375267208,0.000572647200897,-0.002500300062820,-0.000927690649405,-0.000411005516071,0.000505518226419,0.000200112772291) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.005749984178692,-0.006144241895527,-0.008052207529545,-0.008870454505086,-0.002068873494864,0.000292892480502,0.000063370156568,-0.000111667985038,0.016729481518269,0.016144944354892,0.015303568914533,0.014507438056171,-0.002329232171178,-0.000426304002758,0.000553752121050,0.001096601132303) * MODEL6_texOff(vec2(1,0));
res += mat4(-0.002004750771448,-0.002421748358756,-0.004004642833024,-0.006984406616539,0.001026417943649,0.003687470452860,0.001294491696171,-0.002954731462523,-0.006458385381848,-0.002923696767539,0.003673464758322,0.009375544264913,0.004557719919831,0.002435150323436,-0.001211583032273,-0.002594978315756) * MODEL6_texOff(vec2(1,1));
#elif (SHARP == 1)
vec4 res = vec4(-0.000367723114323,-0.000119616968732,-0.000513749313541,-0.000783216150012);
res += mat4(0.013251855038106,0.002139715244994,-0.003592662047595,-0.003767022164539,0.001293804496527,-0.000319959042827,0.000089936955192,0.000672337133437,0.014669951051474,0.002032500226051,-0.006887583993375,-0.006850394885987,0.005107136443257,0.008518467657268,0.005196193233132,0.002265321556479) * MODEL4_texOff(vec2(-1,-1));
res += mat4(-0.013342041522264,0.007257138378918,0.024871140718460,0.024108061566949,0.007244125008583,0.008778261952102,0.009253418073058,0.005061454605311,-0.006051531992853,-0.012454716488719,0.000256215251284,0.015032278373837,-0.025689618662000,-0.031312879174948,-0.027767082676291,-0.012992377392948) * MODEL4_texOff(vec2(-1,0));
res += mat4(-0.005790932569653,-0.009060739539564,-0.012469270266593,-0.015131757594645,0.000904460321181,0.000410668784752,0.002367122331634,0.006267818156630,-0.003177663544193,0.002729568630457,0.011876531876624,0.008450986817479,0.008025774732232,0.010792563669384,0.003128220327199,-0.011799829080701) * MODEL4_texOff(vec2(-1,1));
res += mat4(-0.010857398621738,-0.003597466042265,-0.000779279798735,0.000618654245045,-0.003826713422313,-0.001619663671590,-0.003186310874298,-0.002722945762798,0.005045002326369,-0.009595084935427,-0.011442524380982,-0.009177156724036,0.006560041569173,0.013514268212020,0.011810723692179,0.006554503925145) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.050148013979197,0.032353155314922,-0.000822558358777,-0.017549293115735,-0.045682799071074,-0.046159431338310,-0.033692702651024,-0.016474317759275,-0.039618466049433,-0.006236275658011,0.031908717006445,0.028255995362997,-0.012846499681473,-0.021414559334517,-0.022748004645109,-0.011505696922541) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.003255612449721,-0.002127393614501,0.010121466591954,0.031605556607246,0.006661154795438,0.003711616154760,-0.010023517534137,-0.028958909213543,0.012796708382666,0.020395215600729,0.008266719058156,-0.026259491220117,0.006932488176972,0.010385329835117,0.007245892658830,-0.002139229560271) * MODEL4_texOff(vec2(0,1));
res += mat4(-0.007090282626450,0.001067284261808,0.007556607946754,0.006598712876439,0.002250968245789,-0.002321146661416,-0.003561949357390,-0.001742208958603,0.003426152514294,0.000852998695336,0.000487481069285,0.003257565898821,0.003181718522683,0.002394658513367,0.000119948213978,-0.001238293247297) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.006251919548959,-0.008126081898808,-0.009858562611043,-0.010253947228193,0.021342827007174,0.024295693263412,0.020598949864507,0.012250564992428,-0.001582965720445,-0.005355888046324,-0.004217563197017,0.002752958564088,0.003903541481122,0.003799635451287,0.002451245905831,0.002628363203257) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.001945395371877,-0.004019688814878,-0.005824370309711,-0.006472108419985,-0.003477464430034,-0.003487755544484,0.000998561270535,0.009187687188387,0.000727689708583,0.000067956920248,-0.001262448029593,-0.000313191732857,-0.000691372784786,-0.000575374695472,0.000096915915492,0.001605511526577) * MODEL4_texOff(vec2(1,1));
res += mat4(0.002723033074290,0.009769015945494,0.005930852144957,0.004146991297603,-0.021541871130466,-0.011504871770740,0.003400327404961,0.004422924481332,-0.004678471945226,-0.007447481621057,-0.007008818443865,-0.005259258672595,-0.004153756424785,-0.001211171154864,0.004464483354241,0.002966606291011) * MODEL5_texOff(vec2(-1,-1));
res += mat4(0.024574380367994,-0.005572438705713,-0.032597806304693,-0.019911464303732,0.000885536021087,0.015707070007920,0.015028815716505,-0.010490259155631,-0.018690900877118,-0.012080685235560,-0.005455834791064,-0.003553466871381,-0.032171349972486,0.000928420922719,0.025796705856919,0.014612960629165) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.002891792450100,-0.009021667763591,-0.002434880938381,0.019834810867906,0.000935641175602,-0.000095862174931,-0.004036400932819,-0.006796542089432,0.000324772467138,-0.004655472934246,-0.012962583452463,-0.018755376338959,0.002975844778121,0.009758270345628,-0.000471421401016,-0.028192386031151) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.009568113833666,0.000841307570226,0.006706120446324,0.005762837361544,0.021337721496820,-0.007246332708746,-0.014500707387924,-0.008235206827521,0.017600851133466,0.005893001798540,-0.000520217930898,-0.003180404193699,-0.032082617282867,0.006599187385291,0.018399326130748,0.012014707550406) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.004413345362991,0.031052066013217,0.014196454547346,-0.008186353370547,-0.041709210723639,-0.041383918374777,0.008022867143154,0.039334509521723,0.015661802142859,0.030479114502668,0.036564990878105,0.032319284975529,0.036813087761402,0.033096563071012,-0.014855816960335,-0.053360171616077) * MODEL5_texOff(vec2(0,0));
res += mat4(0.008568141609430,-0.001418844331056,-0.029190890491009,-0.032227702438831,0.003744816174731,0.015045778825879,0.023675329983234,0.001069153891876,0.000117465802759,-0.006031297147274,-0.010943224653602,-0.004676519427449,-0.003906859550625,-0.005929560400546,-0.001950389472768,0.014226664789021) * MODEL5_texOff(vec2(0,1));
res += mat4(-0.003557735821232,-0.000713594548870,-0.000267536612228,0.000391198584111,-0.000247384101385,-0.004559782333672,-0.004003256559372,-0.003905439050868,-0.008265376091003,-0.004776383750141,-0.001537101459689,0.000061799721152,0.003153247293085,0.001543727819808,-0.000685777631588,-0.001408419804648) * MODEL5_texOff(vec2(1,-1));
res += mat4(0.009511081501842,0.006427877116948,-0.003877528244630,-0.007132080849260,-0.000252409867244,0.000988631858490,0.005941991228610,0.006251040380448,-0.003267981810495,-0.006153199356049,-0.009411834180355,-0.011099719442427,-0.003098427085206,0.003777586854994,0.006538052577525,0.003346044104546) * MODEL5_texOff(vec2(1,0));
res += mat4(0.004053953103721,0.004838274326175,0.001806579763070,0.002359339501709,-0.004493542481214,-0.006249580532312,-0.004794769920409,0.000475391774671,0.001662591239437,0.000395950890379,-0.001789004425518,-0.003409060183913,-0.000274330057437,-0.002613328862935,-0.004457820672542,-0.007039382122457) * MODEL5_texOff(vec2(1,1));
res += mat4(-0.016991496086121,-0.003637633984908,0.000284701149212,-0.001629448146559,0.030627515166998,0.014155088923872,-0.010844723321497,-0.013489917851985,-0.007741933222860,-0.004235181957483,-0.001346127130091,0.000454663269920,0.003157846629620,-0.001673805294558,0.002820910653099,0.008935306221247) * MODEL6_texOff(vec2(-1,-1));
res += mat4(-0.023091947659850,-0.041815098375082,-0.050311479717493,-0.040867350995541,-0.001542312209494,-0.018808105960488,-0.022192245349288,0.008960719220340,0.000314846693072,-0.002238720189780,-0.005548484623432,-0.008090566843748,0.053047344088554,0.059398066252470,0.046518240123987,0.021747447550297) * MODEL6_texOff(vec2(-1,0));
res += mat4(-0.013285689987242,-0.010285860858858,-0.005709716118872,-0.008829257450998,0.002983735874295,0.002647595712915,0.002094717696309,0.003947889897972,0.000007118680060,-0.001271464512683,-0.000963765545748,0.000761665403843,0.003878061892465,0.002658030949533,0.008602993562818,0.025638306513429) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.014018279500306,-0.005702201742679,0.001111482037231,0.001724453759380,0.010655582882464,-0.029316807165742,-0.028119934722781,0.001889577601105,0.013656241819263,0.007613272871822,0.002087302273139,-0.001543672988191,0.034291129559278,0.010323395021260,-0.004159306176007,-0.006938689388335) * MODEL6_texOff(vec2(0,-1));
res += mat4(0.024532943964005,0.015317639335990,-0.000662446720526,-0.010187087580562,-0.014379577711225,-0.015049854293466,0.007453384809196,0.031232351437211,0.003268472384661,0.009537125937641,0.016534196212888,0.019788626581430,-0.008148903958499,0.021654093638062,0.050876770168543,0.055284116417170) * MODEL6_texOff(vec2(0,0));
res += mat4(-0.004945967812091,-0.006253404077142,-0.000007850097973,0.011047140695155,0.007154751103371,0.007566252257675,0.002921330975369,-0.003751002717763,0.003867412684485,0.002879594685510,0.000627040921245,0.000098893928225,0.005563234444708,0.002295807702467,-0.005214713513851,-0.010372510179877) * MODEL6_texOff(vec2(0,1));
res += mat4(0.003867034800351,0.004378324374557,0.003792044939473,0.003035793080926,0.008906854316592,0.005304048769176,0.000626742781606,-0.001841987017542,-0.010672821663320,-0.001368499593809,0.001899468596093,0.001682542031631,-0.001382104237564,-0.000920181919355,-0.001278343377635,-0.001431007869542) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.008400755934417,-0.005201966501772,-0.001688166754320,-0.000063803869125,-0.003096287837252,-0.003032699925825,0.000527279509697,0.008060064166784,-0.030609585344791,-0.040105599910021,-0.037277981638908,-0.025673991069198,0.004706830717623,-0.000042489646148,-0.003252424299717,-0.002875249134377) * MODEL6_texOff(vec2(1,0));
res += mat4(0.002641978673637,-0.000893139396794,-0.004045050591230,-0.004962369333953,-0.002188826911151,-0.001019192161039,-0.000900076644029,-0.001139796688221,0.002244378905743,0.004043051041663,-0.000459736562334,-0.013819763436913,0.000280214910163,0.003448975970969,0.005275309085846,0.004255210980773) * MODEL6_texOff(vec2(1,1));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL4
//!BIND MODEL5
//!BIND MODEL6
//!SAVE SUBCONV2
//!DESC [AiUpscale_Fast_4x_Photo_RT] sup-pixel convolution 2

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.000584799970966,-0.000530235760380,-0.001547880470753,-0.000377757271053);
res += mat4(-0.010606870986521,-0.008942953310907,-0.003670677542686,-0.000414284499129,0.008620801381767,0.003050349419937,-0.004893573001027,-0.003622694406658,-0.010979663580656,0.008993943221867,0.011331268586218,0.002928608097136,-0.002474593231454,-0.000796482141595,0.000403962825658,0.000637731631286) * MODEL4_texOff(vec2(-1,-1));
res += mat4(-0.006680396851152,-0.005253973882645,-0.006231589708477,-0.007615690119565,0.001824674080126,-0.003484963439405,-0.008422704413533,-0.000006135174772,0.012956959195435,0.011806329712272,-0.001669046119787,-0.018531396985054,-0.002305399626493,-0.003766728332266,-0.003237834665924,-0.002623922890052) * MODEL4_texOff(vec2(-1,0));
res += mat4(-0.000889913004357,-0.005007932428271,-0.010884485207498,-0.011417164467275,-0.001165268011391,-0.002373501425609,-0.002484972123057,-0.000379220000468,-0.006690471433103,-0.005274533294141,-0.000917858968023,0.007647804450244,-0.000699875527062,-0.000853103003465,-0.001900280825794,-0.002937088022009) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.009436110965908,-0.006443923339248,-0.006842755712569,-0.002510190708563,-0.023279411718249,0.009905606508255,0.013680871576071,0.009578119032085,-0.011253137141466,-0.001402875990607,0.004877886734903,0.001378464163281,0.005654281470925,-0.000740669842344,-0.005385418888181,-0.003855154849589) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.033209979534149,0.047750584781170,0.047078590840101,0.034712702035904,0.044297333806753,0.049209699034691,-0.017718508839607,-0.052626434713602,-0.058280277997255,-0.006862493697554,0.048366341739893,0.016918305307627,-0.027444127947092,-0.023851618170738,-0.012377034872770,-0.001702081994154) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.002223502611741,-0.005008801817894,-0.006293913815171,0.006375237368047,-0.002158489311114,-0.006884533446282,-0.020466210320592,-0.005378304049373,0.000153767221491,0.010280966758728,0.016422480344772,-0.019776511937380,0.005587483756244,0.004719595424831,0.000208621204365,-0.010696607641876) * MODEL4_texOff(vec2(0,1));
res += mat4(-0.009261424653232,-0.006871084682643,-0.003218635218218,-0.000220161746256,0.001651403261349,0.002841844456270,0.001067642122507,-0.001364623429254,-0.008598482236266,-0.003203958040103,-0.003379612229764,-0.000789294950664,0.007225445471704,0.009070502594113,0.002269188873470,-0.004795119166374) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.012098019942641,-0.012155447155237,-0.012747607193887,-0.011297597549856,-0.000168528989889,-0.001792320748791,-0.004508886951953,-0.001021698466502,0.001582458033226,0.013020236045122,0.003116385312751,-0.012866059318185,-0.011311289854348,-0.018604325130582,-0.010309990495443,0.007007387001067) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.000514105369803,-0.003040705807507,-0.008451260626316,-0.012077518738806,0.007271667476743,0.005521390121430,-0.000941657694057,-0.003393843770027,-0.001074954634532,0.002866118447855,0.003105567768216,-0.002333305077627,0.007466669660062,0.007027680985630,0.002459520474076,-0.003877363633364) * MODEL4_texOff(vec2(1,1));
res += mat4(-0.008372462354600,-0.002361060585827,0.004238975234330,0.003698116168380,-0.006743285339326,-0.011350668966770,-0.000346900313161,0.002926834626123,-0.000018913891836,-0.006037724670023,-0.004343605600297,-0.000703292258549,-0.004478092771024,-0.003659573616460,-0.001631330465898,0.001014550216496) * MODEL5_texOff(vec2(-1,-1));
res += mat4(-0.000614653225057,0.008213363587856,0.007057747803628,-0.003429336007684,-0.008409983478487,-0.000291779608233,0.009688831865788,0.007872477173805,-0.007102673407644,-0.012193599715829,-0.002081261714920,0.005295968148857,0.017283169552684,0.018947444856167,0.009398372843862,-0.002838645596057) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.001659886213019,-0.000754633336328,-0.001672900398262,-0.002369217807427,0.003426567884162,0.004769997671247,0.000402399135055,-0.007513308897614,0.000374975759769,-0.000106408617285,0.002353932941332,0.001484694192186,-0.003786290762946,-0.003220198210329,0.000675133953337,0.009436692111194) * MODEL5_texOff(vec2(-1,1));
res += mat4(0.010031446814537,0.016919303685427,0.004014903679490,0.000566529692151,0.029073931276798,-0.011155146174133,-0.013675300404429,-0.004023210145533,-0.037833329290152,-0.008506094105542,0.008978726342320,0.006777329836041,0.036967497318983,0.007595333736390,-0.007703311741352,-0.006994959432632) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.043785538524389,-0.002607545815408,-0.045104052871466,-0.025528848171234,0.020634351298213,-0.044384308159351,-0.028767820447683,0.038427591323853,0.013780308887362,0.036760136485100,0.011371635831892,-0.038068614900112,-0.014883337542415,0.006145501509309,0.042229175567627,0.059236731380224) * MODEL5_texOff(vec2(0,0));
res += mat4(-0.010693552903831,-0.018438881263137,-0.006600137799978,0.029408007860184,-0.005715388339013,-0.010243665426970,0.002824181923643,0.034586276859045,0.001571060391143,0.003269566688687,-0.003574506845325,-0.006433323957026,0.009455444291234,0.006006139330566,-0.005939654540271,-0.015416713431478) * MODEL5_texOff(vec2(0,1));
res += mat4(-0.000217856315430,-0.004599449224770,-0.002033951459453,0.000044866330427,-0.000731747481041,0.000181812851224,0.003321874653921,0.000243504589889,0.001275602728128,0.001527286949567,0.001298717223108,-0.000560109852813,0.004146694671363,0.006895918399096,0.005288670770824,0.003736873390153) * MODEL5_texOff(vec2(1,-1));
res += mat4(-0.000536516017746,-0.003661254420877,0.003154356963933,0.005350030492991,-0.003174252575263,-0.005757036153227,0.003589884145185,0.005164887756109,-0.003428369294852,-0.001536817289889,0.002383755985647,0.002714823465794,-0.003352903528139,-0.008568919263780,-0.007339719217271,-0.001695746672340) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.007128959987313,-0.002444701036438,0.005303045734763,0.006142958067358,-0.004062346182764,-0.007313539739698,-0.003656848100945,0.002986836247146,-0.002270446158946,-0.007821529172361,-0.005453146994114,-0.000887929752935,0.001993970712647,-0.000687449006364,-0.001111528254114,-0.000693758716807) * MODEL5_texOff(vec2(1,1));
res += mat4(0.013836641795933,0.005050037521869,0.000318642996717,-0.000779741501901,0.004909882321954,-0.000882322026882,-0.004384420812130,-0.002885645721108,0.000405238679377,0.000721674121451,0.001324674347416,0.002055787947029,-0.016828346997499,-0.000930429436266,0.008677946403623,0.007550585083663) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.012265224941075,0.025687063112855,0.032134834676981,0.028290936723351,-0.002390128793195,-0.003706398420036,-0.002523489762098,0.003488325979561,0.002601777436212,0.000637519173324,-0.001020142226480,-0.000620501989033,0.008247346617281,-0.007897382602096,-0.024290187284350,-0.027658026665449) * MODEL6_texOff(vec2(-1,0));
res += mat4(0.001365453936160,-0.001502158469521,-0.003181335749105,-0.000932688417379,0.002267575124279,0.000918165897019,-0.002202970441431,-0.002168942242861,-0.000702888413798,-0.000483771611471,-0.000245662871748,0.001290642772801,-0.003564984537661,0.001640206319280,0.005224158521742,0.007043928373605) * MODEL6_texOff(vec2(-1,1));
res += mat4(0.000460164796095,-0.002145866863430,-0.000433478184277,0.003718472551554,0.024356182664633,-0.006076313555241,-0.017190013080835,-0.012759465724230,-0.005744294729084,-0.006878368090838,-0.006026286631823,-0.004385693930089,-0.023547539487481,-0.010186665691435,0.000222198621486,0.003786882385612) * MODEL6_texOff(vec2(0,-1));
res += mat4(0.034139111638069,0.038435142487288,0.028741477057338,0.010080251842737,-0.047213438898325,-0.017494900152087,0.029868816956878,0.047635436058044,-0.011774566955864,-0.011870271526277,-0.011040089651942,-0.008031509816647,-0.024343622848392,-0.031353130936623,-0.037704419344664,-0.039120778441429) * MODEL6_texOff(vec2(0,0));
res += mat4(0.000254760583630,0.000451833824627,0.006725062616169,0.020940637215972,0.014332447201014,0.019365752115846,0.007919743657112,-0.028080312535167,0.000015284851543,-0.002320399275050,-0.004665963351727,-0.007409645710140,-0.001263124402612,-0.002649500500411,-0.004305153153837,-0.010235456749797) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.007429951336235,-0.003690893296152,-0.001050058868714,0.000146295831655,0.000841360539198,0.001354796113446,0.000147287981235,0.001019819290377,0.007266009692103,0.000060597729316,-0.002535440726206,-0.002371212001890,0.001476068748161,0.001308170729317,0.001260124845430,0.000340577331372) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.008083875291049,-0.008012452162802,-0.008736023679376,-0.008750802837312,-0.002617349382490,0.000383549311664,0.000112638845167,0.000487375480589,0.017788408324122,0.022245857864618,0.022397195920348,0.017718166112900,-0.000648601271678,-0.000346196844475,0.000610611808952,0.002122409874573) * MODEL6_texOff(vec2(1,0));
res += mat4(-0.002235585357994,-0.002736922819167,-0.004828353878111,-0.008926895447075,0.002384478691965,0.005083599593490,0.001576627139002,-0.004320790525526,-0.005325843580067,-0.004122326150537,0.000377438933356,0.007022569421679,0.003387958509848,0.003032836131752,0.000471226172522,-0.000970150693320) * MODEL6_texOff(vec2(1,1));
#elif (SHARP == 1)
vec4 res = vec4(0.000057356501202,0.000603233405855,0.000165224730154,-0.000342250190442);
res += mat4(-0.005631204228848,-0.004284218419343,-0.002676580566913,-0.002686314983293,-0.003669226309285,-0.002025822643191,0.000668797700200,0.002306276001036,0.008190888911486,0.004080832470208,-0.001675338717178,-0.002284689107910,0.012244685553014,0.009683649055660,0.003615622641519,0.000268137315288) * MODEL4_texOff(vec2(-1,-1));
res += mat4(0.009814690798521,0.011777480132878,0.004243452101946,-0.005252504721284,-0.000721024174709,-0.001368858036585,-0.001660975161940,-0.004026871640235,0.001494244905189,-0.002329557202756,-0.003413313534111,0.001989152049646,-0.004588807933033,-0.005678290966898,-0.003456151578575,0.004671396221966) * MODEL4_texOff(vec2(-1,0));
res += mat4(-0.001944534247741,0.000178339119884,0.003008005209267,0.007212952710688,0.000584548222832,0.000167967140442,0.000229775017942,0.000553360732738,-0.002240237547085,0.000074926370871,0.003128847340122,0.003038803348318,0.007914521731436,0.010799719020724,0.007223224733025,0.000074269417382) * MODEL4_texOff(vec2(-1,1));
res += mat4(-0.011054259724915,-0.005536851473153,-0.003867112332955,-0.002214216394350,0.011694292537868,0.003419637680054,-0.002797886729240,-0.002915191231295,0.008092375472188,-0.011503320187330,-0.013566100969911,-0.010185247287154,0.001058023655787,0.011815304867923,0.011757235974073,0.006995256524533) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.013640778139234,-0.012173807248473,-0.030093107372522,-0.024267338216305,-0.008740765973926,0.000225191208301,0.009452206082642,0.013471718877554,-0.050602499395609,-0.021389007568359,0.032144632190466,0.038288053125143,-0.023591943085194,-0.033729631453753,-0.035978972911835,-0.022605402395129) * MODEL4_texOff(vec2(0,0));
res += mat4(0.000822462083306,0.002960200188681,0.009121891111135,0.015509170480072,0.002746226266026,0.001354994950816,-0.003077806672081,-0.008140036836267,0.009088711813092,0.023061566054821,0.020106228068471,-0.019649181514978,0.007564804051071,0.009364967234433,0.002807255601510,-0.009979919530451) * MODEL4_texOff(vec2(0,1));
res += mat4(0.001332313404419,0.007123332470655,0.010544484481215,0.007825822569430,0.002358115045354,-0.000886611349415,-0.000271732918918,0.001622985349968,0.005086096469313,0.000706866150722,-0.001154049881734,0.001180103048682,0.006559792906046,0.005993314553052,0.003413794096559,0.000874305551406) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.012048224918544,-0.010349243879318,-0.005115487147123,-0.001466057263315,0.044324170798063,0.045337051153183,0.034138090908527,0.016171848401427,-0.001127233612351,-0.003990999422967,-0.003207465168089,0.004251855891198,0.004952628631145,0.004297976382077,0.003160090884194,0.004536090418696) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.001300244475715,-0.002643171930686,-0.005322610028088,-0.009181448258460,-0.005872738081962,-0.003596941009164,0.007513469550759,0.024992223829031,0.002749122912064,0.000261673325440,-0.003730724100024,-0.002561145462096,0.000327528949128,0.001168205984868,0.002125502098352,0.003338515525684) * MODEL4_texOff(vec2(1,1));
res += mat4(0.007429860532284,0.003915395587683,0.000389871449443,0.001159588922746,-0.010547393932939,-0.001913231448270,0.004528196528554,0.002593406708911,-0.004499260336161,-0.004462035838515,-0.002820530207828,-0.001831319183111,-0.001619399175979,0.000912632676773,0.001767000649124,-0.001326263998635) * MODEL5_texOff(vec2(-1,-1));
res += mat4(0.008284805342555,-0.005780265666544,-0.011855810880661,0.000763498188462,0.002677096752450,0.003421489149332,0.000676016963553,-0.010043676942587,-0.013969025574625,-0.010454789735377,-0.006638289429247,-0.005099058616906,-0.016899615526199,-0.004378359764814,0.007596729323268,0.003921503666788) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.001498531899415,-0.004611653275788,-0.002298106905073,0.007926422171295,-0.001438273233362,-0.002986816922203,-0.001110778539442,0.001585683086887,-0.000458792113932,-0.004642500076443,-0.011093656532466,-0.014961461536586,0.003380833426490,0.007460121996701,0.004316385369748,-0.010676116682589) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.015348728746176,0.006874055601656,0.012130641378462,0.007457112427801,0.009385903365910,-0.019345846027136,-0.016238778829575,-0.005333791486919,0.021006405353546,0.007428158540279,-0.000005412158316,-0.002644302323461,-0.036394562572241,0.000318709819112,0.016864243894815,0.011366452090442) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.032544501125813,0.041461244225502,-0.003863669233397,-0.031072817742825,-0.053925015032291,-0.028257293626666,0.033429563045502,0.047814287245274,0.014798701740801,0.031468547880650,0.038931287825108,0.035456582903862,0.019892010837793,0.044713143259287,0.009782661683857,-0.042997568845749) * MODEL5_texOff(vec2(0,0));
res += mat4(0.004102214239538,-0.010778714902699,-0.032482467591763,-0.016214676201344,0.007598268799484,0.020773524418473,0.020050095394254,-0.016003808006644,0.002201438648626,-0.005242026410997,-0.012181119062006,-0.006566056516021,0.002504119882360,0.001627450925298,-0.007830466143787,-0.008748611435294) * MODEL5_texOff(vec2(0,1));
res += mat4(-0.000782515155151,0.000696822884493,-0.000098580560007,0.000165271194419,-0.000437927839812,-0.002867104485631,-0.002414165530354,-0.003398520639166,-0.008942513726652,-0.005666150245816,-0.002032387768850,-0.000014129578631,0.002767219208181,0.003698171349242,0.001554728252813,0.000678857613821) * MODEL5_texOff(vec2(1,-1));
res += mat4(0.004505701363087,0.002227589720860,-0.005092383362353,-0.005098761990666,0.006827396340668,0.002970823319629,0.002515376545489,0.002572071040049,-0.002808135235682,-0.004930096212775,-0.007631406188011,-0.009671256877482,-0.001714470447041,0.001853144494817,0.002904268214479,0.001423291629180) * MODEL5_texOff(vec2(1,0));
res += mat4(0.004698213189840,0.006281483452767,0.002165183890611,-0.000078153898357,-0.005261128302664,-0.008224528282881,-0.004167653154582,0.005786760244519,0.002410503569990,0.001293985289522,-0.001442409353331,-0.003644019830972,-0.004489725921303,-0.003701995126903,-0.002232344821095,-0.003303532954305) * MODEL5_texOff(vec2(1,1));
res += mat4(-0.004187896847725,-0.004163958597928,-0.002264622598886,-0.000401804514695,0.012021359056234,0.004987728781998,-0.004578180145472,-0.003643073607236,-0.000699787400663,-0.001370558864437,-0.001718155806884,-0.001415174687281,0.008700568228960,0.004820277448744,0.003450677264482,0.004001642577350) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.019350128248334,0.016565859317780,0.004645675886422,-0.005996842868626,0.001915064989589,-0.006323919631541,-0.011265759356320,0.001704932190478,0.004765040241182,0.005715853534639,0.005022525321692,0.002431648783386,0.008097266778350,0.013464717194438,0.020526418462396,0.019798148423433) * MODEL6_texOff(vec2(-1,0));
res += mat4(-0.007848169654608,-0.006148479413241,0.001081895432435,0.011423145420849,0.000102691308712,-0.000013503613445,0.000276333536021,0.003782286075875,-0.001051702769473,-0.001789765083231,-0.000390478264308,0.002741598291323,0.003749958937988,0.001460324390791,-0.001461621955968,-0.001250816858374) * MODEL6_texOff(vec2(-1,1));
res += mat4(0.014012278057635,0.007362784817815,0.003095417050645,-0.000128591520479,0.036648929119110,-0.021666573360562,-0.040641326457262,-0.011012147180736,-0.006179577670991,-0.000711936678272,0.000789599027485,-0.000842194654979,0.014521493576467,0.006419039797038,-0.002751544117928,-0.006761189084500) * MODEL6_texOff(vec2(0,-1));
res += mat4(0.032719351351261,0.041145075112581,0.040612280368805,0.032238911837339,-0.018964657559991,-0.028900822624564,-0.000825710012577,0.047243114560843,-0.024855010211468,-0.028296943753958,-0.024177869781852,-0.014827435836196,-0.033186901360750,-0.022317660972476,-0.001576328999363,0.012115449644625) * MODEL6_texOff(vec2(0,0));
res += mat4(0.000688320782501,-0.003408434102312,-0.000554140773602,0.012347466312349,0.008119010366499,0.008567350916564,0.003237238619477,-0.004613178316504,0.004262555856258,0.002322204876691,-0.003864926984534,-0.012943583540618,0.003354955697432,0.004976034164429,-0.001411726116203,-0.016017396003008) * MODEL6_texOff(vec2(0,1));
res += mat4(0.005331602878869,0.006287989672273,0.004570353776217,0.002726168138906,0.003943865187466,0.005382696166635,0.003953591454774,0.000091293746664,-0.019744250923395,-0.007138658780605,-0.000350438320311,0.000541715184227,-0.006911295000464,-0.003385706339031,-0.001195721677504,-0.000473626103485) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.010979792103171,-0.008475360460579,-0.003750918665901,-0.000299822248053,0.000400410033762,-0.000679195334669,-0.001424401183613,0.001709437347017,-0.026939414441586,-0.039064437150955,-0.042762592434883,-0.033373251557350,0.007185862865299,-0.000430843560025,-0.007577443495393,-0.009128468111157) * MODEL6_texOff(vec2(1,0));
res += mat4(0.005000607110560,0.002678856719285,-0.001250559464097,-0.004492956213653,-0.003569666529074,-0.001981470733881,-0.000620219158009,0.000405837257858,0.000168280748767,0.001738048507832,-0.002570302458480,-0.015321458689868,-0.000879247323610,0.000754612556193,0.003564924467355,0.005657786969095) * MODEL6_texOff(vec2(1,1));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL4
//!BIND MODEL5
//!BIND MODEL6
//!SAVE SUBCONV3
//!DESC [AiUpscale_Fast_4x_Photo_RT] sup-pixel convolution 3

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.000986639061011,0.000222484319238,-0.001057362882420,-0.000230183883104);
res += mat4(-0.009910343214869,-0.006462653633207,-0.001834974391386,0.000009059431250,0.002229458186775,-0.000229320561630,-0.005676859058440,-0.005818389821798,-0.002125499770045,0.006190839689225,0.008609092794359,0.003116830950603,0.000652902235743,0.002172355540097,0.003257160540670,0.002197094494477) * MODEL4_texOff(vec2(-1,-1));
res += mat4(-0.008183596655726,-0.008666057139635,-0.009973403997719,-0.010280018672347,-0.002833681413904,0.003721218788996,0.002404800150543,-0.000206651267945,0.004121034871787,0.001550271874294,0.003644531592727,0.000142356453580,0.004176059737802,0.002558610169217,0.001589612918906,0.001015743124299) * MODEL4_texOff(vec2(-1,0));
res += mat4(0.000821498455480,-0.002584473928437,-0.007793921045959,-0.009621763601899,0.000407660234487,0.000472090410767,-0.001323842676356,-0.005446164868772,-0.003704625880346,-0.006959018763155,-0.005185966845602,0.003614833345637,0.000514453509822,0.001558484393172,0.001933942898177,0.002749052830040) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.005631776992232,-0.008494724519551,-0.007692076265812,-0.003773255506530,-0.003726827446371,0.019882975146174,0.011683995835483,0.006244269199669,-0.048454288393259,-0.001518391189165,0.017192777246237,0.007236198987812,0.008661123923957,-0.000867715978529,-0.004210093058646,-0.000968277570792) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.034919910132885,0.048174645751715,0.044146951287985,0.029588829725981,0.053232423961163,0.029510127380490,-0.041689455509186,-0.048551987856627,-0.035596270114183,0.030781602486968,0.047761376947165,-0.031820710748434,0.024871652945876,0.030819550156593,0.025510579347610,0.015115092508495) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.002804601565003,-0.006080142688006,-0.007647357415408,0.006407295819372,-0.006086218636483,-0.008731575682759,-0.013202807866037,0.010582114569843,-0.001327750971541,0.008221236988902,0.009938108734787,-0.021246945485473,0.002076423726976,0.003446513554081,0.010947374626994,0.020193694159389) * MODEL4_texOff(vec2(0,1));
res += mat4(-0.009695134125650,-0.009044514037669,-0.005638051778078,-0.002298099687323,-0.000591531628743,-0.000572352204472,-0.000011182695744,-0.000438552757259,0.003296451643109,0.004566799383610,-0.003167774761096,-0.004504343029112,0.008187456056476,0.002019607927650,0.001146793598309,0.001586630125530) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.011560959741473,-0.009695245884359,-0.010086608119309,-0.009629405103624,-0.002776270965114,0.001711632357910,0.001891131047159,0.001779545331374,-0.000819214095827,0.004887931980193,-0.001290794461966,-0.005803561303765,0.070444017648697,0.072853356599808,0.054638687521219,0.031424354761839) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.001307285274379,-0.004941234830767,-0.012198938056827,-0.015277833677828,0.004047040361911,0.003710180521011,-0.002327602589503,-0.006010241340846,-0.000644892163109,0.002810904989019,0.005115386564285,-0.000624483451247,0.002630312694237,0.006713596172631,0.019736031070352,0.042821004986763) * MODEL4_texOff(vec2(1,1));
res += mat4(-0.000038415713789,-0.002953672781587,0.000002578199656,0.001810504938476,-0.002528656972572,-0.004225877113640,0.000520993897226,0.003247779561207,-0.002771152183414,-0.005894917994738,-0.006157316267490,-0.000940294004977,0.005075252614915,0.001038171350956,-0.000391334295273,-0.000226538104471) * MODEL5_texOff(vec2(-1,-1));
res += mat4(-0.008241440169513,-0.006328613962978,0.000596413563471,0.003974580205977,0.005688056349754,0.001858920091763,-0.005634217057377,-0.003970385529101,0.007836528122425,0.001654541003518,-0.001790482667275,-0.002446191851050,0.002714943839237,0.007972456514835,0.010961262509227,0.008615182712674) * MODEL5_texOff(vec2(-1,0));
res += mat4(0.000258767482592,0.001507943728939,0.001393617480062,-0.001657822169363,0.002136557828635,0.004742063581944,0.002460635034367,0.000767444318626,0.001157120568678,0.001133055891842,0.002633300377056,0.005361662246287,-0.002663275459781,-0.003607060294598,-0.003895265515894,-0.000616724952124) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.018513781949878,0.014003761112690,0.014487987384200,0.006086317356676,0.031730882823467,-0.025671124458313,-0.019271519035101,-0.003192317206413,-0.009809904731810,-0.007693135179579,0.001675710431300,0.003480100538582,0.011712130159140,0.004709051921964,-0.002932526869699,-0.003964726347476) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.058865606784821,0.031963221728802,-0.032800961285830,-0.052531950175762,-0.014680776745081,-0.052088133990765,0.006280466448516,0.075270734727383,-0.021416813135147,0.014499495737255,0.036551631987095,0.010960724204779,-0.033879362046719,-0.040896281599998,-0.023610293865204,0.003646221477538) * MODEL5_texOff(vec2(0,0));
res += mat4(-0.009262184612453,-0.018071258440614,-0.014596205204725,0.022437945008278,0.003031342057511,-0.001491333474405,0.003262844402343,0.012829881161451,0.002563273767009,0.007765377871692,0.003084265394136,-0.015982521697879,0.003994292579591,0.004558203276247,-0.004614171572030,-0.019514147192240) * MODEL5_texOff(vec2(0,1));
res += mat4(0.004892626777291,-0.001711204065941,-0.001479525351897,0.000265253358521,-0.006383064202964,0.001306680147536,0.007194757927209,0.004653904121369,0.002467256272212,0.003089939244092,0.003554467344657,0.002889089519158,-0.016333069652319,-0.001947778509930,0.006887495052069,0.007456459105015) * MODEL5_texOff(vec2(1,-1));
res += mat4(-0.000377873511752,-0.007477320265025,-0.000232587030041,0.008563279174268,0.008234268054366,-0.002531586680561,-0.005054864101112,-0.006549654528499,0.004439704120159,-0.001112242229283,-0.002748311730102,-0.000219691588427,0.011301538906991,-0.001656856155023,-0.019103871658444,-0.026917280629277) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.004497546236962,-0.003238106844947,0.003207925707102,0.006714207585901,-0.004441960249096,-0.007378594949841,-0.003413018770516,0.008892441168427,-0.002376915188506,-0.005488422699273,-0.000724083976820,0.007036839146167,0.000917537079658,-0.001281847013161,0.000568769057281,0.008334717713296) * MODEL5_texOff(vec2(1,1));
res += mat4(-0.001381418434903,0.000890484196134,0.003407630603760,0.003079099580646,0.002218278124928,-0.000225647410844,-0.001386586111039,-0.001285725506023,-0.005321254022419,-0.001352278515697,0.000994392205030,0.001754157128744,-0.020211024209857,-0.006416389252990,0.001207978348248,0.001862382749096) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.029393427073956,0.022907407954335,0.011172026395798,0.004226071294397,-0.004649285692722,-0.003122202120721,-0.000476328743389,0.002071440452710,-0.012910876423120,-0.015766894444823,-0.014909875579178,-0.010872885584831,-0.022639369592071,-0.031994163990021,-0.034914694726467,-0.032374452799559) * MODEL6_texOff(vec2(-1,0));
res += mat4(-0.001843140111305,0.004289084114134,0.014421403408051,0.020594552159309,-0.001219901721925,-0.001025475328788,-0.001596238464117,-0.002322352956980,0.001689746975899,0.000148881226778,-0.003635128727183,-0.007871272042394,-0.002999278716743,-0.003748938441277,-0.008314406499267,-0.014166642911732) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.008915008045733,-0.002416549017653,0.001238375320099,0.003765854984522,0.024303287267685,-0.004388273693621,-0.015879094600677,-0.010980588383973,0.010854821652174,-0.001396345556714,-0.005998434033245,-0.005775860510767,-0.006842543371022,-0.001213881070726,0.000703945930582,0.000019607316062) * MODEL6_texOff(vec2(0,-1));
res += mat4(0.002025309717283,-0.007156393025070,-0.016125485301018,-0.020070157945156,-0.035268798470497,-0.020575784146786,0.015657640993595,0.039217792451382,0.012692431919277,0.023452891036868,0.026657432317734,0.023158762603998,-0.044000104069710,-0.047913942486048,-0.035475600510836,-0.018935941159725) * MODEL6_texOff(vec2(0,0));
res += mat4(0.000820976099931,0.004147125873715,0.007360858842731,0.009283849038184,0.012210354208946,0.015851136296988,0.007852467708290,-0.018007289618254,-0.000992190558463,-0.003401155350730,-0.004172250628471,0.001535691902973,0.006000793073326,0.005200638901442,-0.003863235935569,-0.021613122895360) * MODEL6_texOff(vec2(0,1));
res += mat4(0.003612119471654,0.003112033009529,0.000413603207562,-0.001380343106575,0.003457453800365,-0.000060701739130,-0.004380896687508,-0.004651044495404,-0.002877413993701,-0.002730655251071,-0.000594993412960,0.001134751830250,0.006237864028662,0.002450120868161,0.000944781233557,0.000292627722956) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.008148730732501,-0.007141765207052,-0.002953313756734,0.001832410576753,-0.010225947014987,-0.001579868374392,0.004437753465027,0.005309488158673,0.000017042209947,0.002015327801928,0.001508691930212,-0.001013047643937,0.005331786349416,0.006867490708828,0.007866176776588,0.007758116815239) * MODEL6_texOff(vec2(1,0));
res += mat4(0.000694803195074,0.001228649518453,-0.000301188701997,-0.005034502595663,0.002751542255282,0.004580980632454,-0.000208138240851,-0.009848994202912,-0.000887727190275,-0.001785455620848,-0.001913890591823,-0.001376730855554,0.000055107851949,0.000743766722735,0.000386584375519,0.001607498852536) * MODEL6_texOff(vec2(1,1));
#elif (SHARP == 1)
vec4 res = vec4(0.000523352704477,0.001217902521603,0.000796945590992,0.000259116000962);
res += mat4(-0.006278460845351,-0.003645668970421,-0.002955015981570,-0.002469941042364,-0.006337765604258,-0.003087105229497,0.000817681255285,0.002677995478734,0.001530174864456,0.004001265391707,0.001597670139745,0.000527636148036,0.014772077091038,0.009699799120426,0.003163342131302,0.000462820520625) * MODEL4_texOff(vec2(-1,-1));
res += mat4(0.009672230109572,0.002765024313703,-0.007584515959024,-0.011529773473740,-0.005462203174829,-0.007156999316067,-0.008174322545528,-0.009024801664054,-0.001662940019742,-0.000246010051342,-0.003597686998546,-0.004096319898963,0.009395423345268,0.011038168333471,0.011571513488889,0.013991234824061) * MODEL4_texOff(vec2(-1,0));
res += mat4(0.006135408766568,0.009829725138843,0.010595712810755,0.010929723270237,0.000165353470948,-0.000566339411307,-0.002153214300051,-0.004047946073115,-0.000646405387670,0.000793030136265,-0.000751614279579,-0.003297523129731,0.005079721100628,0.007761819288135,0.008126425556839,0.007349151186645) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.012702563777566,0.002711877459660,-0.006685033906251,-0.007406668737531,0.014812065288424,0.002974797040224,-0.004205030389130,-0.005037678871304,0.014486407861114,-0.008142719976604,-0.013104523532093,-0.010115512646735,0.001637752749957,0.012875145301223,0.012858785688877,0.008742399513721) * MODEL4_texOff(vec2(0,-1));
res += mat4(-0.036638073623180,-0.041214130818844,-0.017435012385249,0.010945296846330,0.013247698545456,0.022779228165746,0.027262488380075,0.024206986650825,-0.045228496193886,-0.031961198896170,0.021229784935713,0.040428176522255,-0.028750166296959,-0.037756085395813,-0.038527984172106,-0.023702515289187) * MODEL4_texOff(vec2(0,0));
res += mat4(0.006012650206685,0.006031807977706,-0.001889808801934,-0.017263060435653,-0.001890959218144,-0.000593194446992,0.002090112073347,0.005800595507026,0.001601114054210,0.016968345269561,0.025147859007120,-0.006301560904831,0.009286465123296,0.010494026355445,0.002086587483063,-0.013492663390934) * MODEL4_texOff(vec2(0,1));
res += mat4(0.007282855454832,0.006908870767802,0.004263737238944,0.001181705854833,-0.007640532217920,-0.002512872451916,0.001501376042143,0.002929624635726,0.004551512189209,-0.001357220462523,-0.003917496185750,-0.002331127645448,0.011038627475500,0.010928205214441,0.007412855047733,0.003631176427007) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.004594121128321,0.000904521089979,0.006615591235459,0.007791634649038,0.017438651993871,0.011211768724024,0.003321766853333,-0.004372632596642,-0.005029793828726,-0.000011225485650,0.003955754451454,0.006665680557489,0.004591201897711,0.002780500566587,0.002681545447558,0.006313330959529) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.002845678711310,-0.004154029767960,-0.005411668680608,-0.005364907439798,-0.001533038099296,0.000442074844614,0.005295039620250,0.011490460485220,0.005926601588726,0.004205500707030,-0.003771913936362,-0.008369506336749,0.003209015587345,0.005868639796972,0.006837551947683,0.006089597009122) * MODEL4_texOff(vec2(1,1));
res += mat4(0.006060252897441,-0.000668098567985,-0.002886499976739,-0.001582873635925,-0.001269137719646,0.003141186665744,0.005967897828668,0.003836814081296,-0.000920753169339,-0.001017013913952,0.000542108551599,0.000849937379826,-0.003054051427171,0.000285094720311,-0.000317401485518,-0.002753280336037) * MODEL5_texOff(vec2(-1,-1));
res += mat4(0.002561356406659,0.000006354140623,0.001120038330555,0.007689526304603,-0.001415719510987,-0.003726351773366,-0.000609067676123,-0.001322555937804,-0.004270787816495,-0.001989185577258,-0.000598557584453,-0.000854361744132,-0.001224643900059,-0.000178066096851,0.000419486954343,-0.004045169800520) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.002354572294280,-0.005221937783062,-0.005301308818161,0.000680422643200,-0.000659702287521,-0.002459966344759,0.000017406295228,0.001686070114374,0.000691792054567,-0.002258368069306,-0.006477154325694,-0.007261944003403,0.004096641205251,0.006200727075338,0.006255795713514,0.001215709722601) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.012350889854133,0.014483100734651,0.013880461454391,0.006432273890823,-0.011977594345808,-0.026096066460013,-0.009358092211187,0.001933097722940,0.014895796775818,0.002901563886553,-0.003415936604142,-0.004417438991368,-0.026528786867857,-0.004812106024474,0.011366317979991,0.009850665926933) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.053450882434845,0.032972015440464,-0.030371217057109,-0.047550275921822,-0.038654141128063,0.002601210260764,0.048466637730598,0.032616734504700,0.003445305628702,0.018394522368908,0.026729190722108,0.025248773396015,-0.015488896518946,0.037047307938337,0.037939991801977,-0.009479649364948) * MODEL5_texOff(vec2(0,0));
res += mat4(-0.003625017823651,-0.017549104988575,-0.021776396781206,0.012862927280366,0.008607885800302,0.017280019819736,0.008068036288023,-0.024018766358495,0.003841560799628,-0.003609165083617,-0.012246580794454,-0.010692654177547,0.006304714828730,0.010049287229776,-0.008750998415053,-0.034197788685560) * MODEL5_texOff(vec2(0,1));
res += mat4(0.002210560953245,0.001742896158248,0.001095515675843,0.001146950293332,0.002368205925450,-0.001119131920859,-0.002328364178538,-0.002647101180628,-0.004893359262496,-0.004412157461047,-0.001861484604888,-0.000414527545217,-0.002543793059886,0.006820370443165,0.006534706801176,0.004413000773638) * MODEL5_texOff(vec2(1,-1));
res += mat4(-0.005388041958213,0.002031965414062,0.001263143494725,0.001799938851036,0.007057479117066,-0.006007405929267,-0.005909783765674,0.001295357709751,-0.000547965697479,0.000618940510321,-0.000087293759861,-0.001859026961029,0.007693971972913,0.003328518010676,-0.006944237742573,-0.010290253907442) * MODEL5_texOff(vec2(1,0));
res += mat4(0.006580643355846,0.007488215342164,-0.002672441303730,-0.011231523938477,-0.004111608490348,-0.005284353625029,0.002776150824502,0.012720908038318,-0.000256696279394,-0.002780445385724,-0.005923936143517,-0.006372331175953,-0.006991322617978,-0.004492247942835,0.001107068499550,0.006036722566932) * MODEL5_texOff(vec2(1,1));
res += mat4(0.010826839134097,0.002254384569824,-0.000911949900910,-0.000502709124703,0.005543882492930,-0.001498390105553,-0.005721360445023,-0.001155933132395,0.003323394572362,0.000269770214800,-0.001428929273970,-0.002205173717812,-0.003689569421113,0.002169374143705,0.002901876578107,0.000060982918512) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.021655300632119,0.026728942990303,0.025245659053326,0.017955267801881,0.001492151641287,-0.000832921010442,-0.002346455352381,0.003347469260916,0.007890684530139,0.010480175726116,0.010939017869532,0.008371726609766,-0.018675265833735,-0.020576165989041,-0.013010193593800,-0.004033386707306) * MODEL6_texOff(vec2(-1,0));
res += mat4(0.001147698145360,0.001682687317953,0.004281732253730,0.012005220167339,-0.001726709771901,-0.001599199022166,-0.000850543961860,0.002117152558640,-0.002323773922399,-0.002976241754368,-0.000709103827830,0.003802633378655,-0.002640513237566,-0.005074811633676,-0.009499697014689,-0.015637418255210) * MODEL6_texOff(vec2(-1,1));
res += mat4(0.024237032979727,0.013184818439186,0.001577913062647,-0.004862011875957,0.056833475828171,0.000214272091398,-0.037355281412601,-0.023054691031575,-0.012639007531106,-0.005678869783878,0.000138670307933,0.002277144929394,-0.030755298212171,-0.010207618586719,-0.000542424211744,-0.000393926835386) * MODEL6_texOff(vec2(0,-1));
res += mat4(0.004890921991318,0.014125826768577,0.028527699410915,0.035218421369791,-0.016750333830714,-0.036870062351227,-0.015925722196698,0.045851241797209,-0.013370761647820,-0.015767674893141,-0.017774434760213,-0.018629405647516,-0.035257924348116,-0.056786436587572,-0.068866759538651,-0.061099156737328) * MODEL6_texOff(vec2(0,0));
res += mat4(0.006121467333287,0.006251850631088,0.005767740774900,0.005567056126893,0.006853515282273,0.006986929103732,0.003345342352986,-0.003082795068622,0.001850309316069,-0.000885523797479,-0.004106685519218,-0.006924916524440,-0.005065630655736,-0.001950834295712,-0.002082952996716,-0.011910058557987) * MODEL6_texOff(vec2(0,1));
res += mat4(0.000728226674255,0.004329608287662,0.003492847084999,0.002134778071195,-0.004563894588500,-0.003164550755173,0.002305479021743,0.003658607136458,0.000777946377639,-0.002131334505975,-0.001352734398097,0.001181858126074,-0.009224265813828,-0.005302649922669,-0.000413715315517,0.001047576777637) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.007331305649132,-0.011105317622423,-0.010106212459505,-0.006619280669838,0.000992373796180,-0.000298588158330,-0.001283338060603,-0.002119315788150,0.026636125519872,0.034035488963127,0.026868574321270,0.013565662316978,0.005515779834241,0.000930399517529,-0.005823590327054,-0.008229136466980) * MODEL6_texOff(vec2(1,0));
res += mat4(0.004376812372357,0.005744968540967,0.004636957775801,0.000706282909960,-0.002104824176058,0.000007202371307,0.001780217746273,0.002483484335244,-0.001326017314568,-0.002514879452065,0.000322124193190,0.008206797763705,-0.001605091732927,-0.003101715352386,-0.001499342033640,0.001530524343252) * MODEL6_texOff(vec2(1,1));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!COMPONENTS 4
//!BIND MODEL4
//!BIND MODEL5
//!BIND MODEL6
//!SAVE SUBCONV4
//!DESC [AiUpscale_Fast_4x_Photo_RT] sup-pixel convolution 4

vec4 hook()
{

#if (SHARP == 0)
vec4 res = vec4(0.001291313557886,0.000884556386154,-0.000414698355598,0.000009801625311);
res += mat4(-0.005954808555543,-0.003045638091862,-0.000131085107569,0.000138963689096,0.000295510457363,0.000556631188374,-0.004035773221403,-0.005266832187772,-0.004574622493237,0.003381002694368,0.008450007066131,0.003305006073788,0.001357784960419,0.001171968993731,0.002035960322246,0.001923383679241) * MODEL4_texOff(vec2(-1,-1));
res += mat4(-0.004217121284455,-0.004297771025449,-0.005581766832620,-0.006478030700237,0.001006828038953,0.008259500376880,0.004438402596861,-0.001781247905456,-0.001687088981271,0.003698510117829,0.009934713132679,0.002613165415823,0.006005864590406,0.005932327359915,0.005693675484508,0.003977636341006) * MODEL4_texOff(vec2(-1,0));
res += mat4(0.001537102391012,-0.000950120331254,-0.004398779943585,-0.005539508070797,0.000713356188498,0.001160928164609,-0.000594158598687,-0.003645892720670,0.000254600454355,-0.005927687976509,-0.007102842908353,-0.002307004993781,0.002397094154730,0.003470606869087,0.003298150142655,0.004481396637857) * MODEL4_texOff(vec2(-1,1));
res += mat4(-0.002627215581015,-0.011254914104939,-0.008600847795606,-0.004468575585634,0.011812960729003,0.020112831145525,0.006051127333194,0.002352943876758,-0.060213603079319,0.001479684258811,0.020397925749421,0.007175591774285,0.001469243667088,-0.001337766647339,-0.003013843903318,-0.002058473881334) * MODEL4_texOff(vec2(0,-1));
res += mat4(0.020989123731852,0.031262509524822,0.026805900037289,0.014372834004462,0.042975895106792,0.004694362170994,-0.046304423362017,-0.028708184137940,0.001605457277037,0.052606936544180,0.026425534859300,-0.063430584967136,0.017899457365274,0.016992358490825,0.010113543830812,0.004505041055381) * MODEL4_texOff(vec2(0,0));
res += mat4(-0.004353729542345,-0.009364988654852,-0.012843816541135,-0.002183695090935,-0.006818393245339,-0.007730801124126,-0.002958473982289,0.020168747752905,-0.003499175887555,0.001622289419174,0.001932149985805,-0.008930927142501,-0.004439372103661,-0.003824557876214,0.001748460344970,0.010264582000673) * MODEL4_texOff(vec2(0,1));
res += mat4(-0.006858599372208,-0.011934803798795,-0.010124977678061,-0.005557620432228,-0.011133667081594,-0.002669297158718,0.003567395964637,0.003682303940877,0.016610031947494,0.007424178067595,-0.003470425028354,-0.005919611547142,-0.002779313363135,-0.001651123398915,0.001911879982799,0.002946922788396) * MODEL4_texOff(vec2(1,-1));
res += mat4(-0.002418507123366,0.003632862353697,0.004124893341213,0.001163739594631,0.002320881001651,0.016835855320096,0.008169110864401,-0.007210924290121,-0.018210554495454,-0.010280011221766,0.006512392312288,0.014227881096303,0.024161314591765,0.021110845729709,0.007366623263806,-0.002255114726722) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.001484853331931,-0.006057704333216,-0.012830932624638,-0.012270151637495,0.000417364499299,-0.000379183475161,-0.009939626790583,-0.012003513984382,0.000479487673147,0.005235413089395,0.009723894298077,-0.003836937947199,-0.010592569597065,-0.008692352101207,-0.001863951561972,0.007839074358344) * MODEL4_texOff(vec2(1,1));
res += mat4(0.001272170455195,0.000700558361132,0.001719466759823,0.001400107285008,0.002540863584727,-0.003331457497552,-0.001700098277070,0.002955667441711,-0.000813016376924,-0.005501446314156,-0.006686966400594,-0.000523021328263,0.005548871587962,0.003398544620723,0.002361302729696,0.001535539980978) * MODEL5_texOff(vec2(-1,-1));
res += mat4(-0.003943021409214,-0.005691795144230,-0.003840472782031,0.000424960540840,0.006297510582954,-0.004823891911656,-0.009996796958148,-0.001141957589425,0.007043479941785,0.003898231778294,0.001283322111703,-0.000654540257528,-0.000775434426032,0.002748159924522,0.005747871473432,0.006230029743165) * MODEL5_texOff(vec2(-1,0));
res += mat4(0.002253517974168,0.002236149273813,0.001275852322578,-0.000148179809912,0.001206538872793,0.005094091407955,0.004723978694528,0.004651096183807,0.000403898768127,0.001737963291816,0.002986004343256,0.003404274582863,-0.000831470882986,-0.002686812542379,-0.004356400109828,-0.002985830884427) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.035047065466642,0.006372692994773,0.019404511898756,0.009689336642623,0.019230719655752,-0.029364969581366,-0.015796473249793,-0.000328361435095,0.015805028378963,-0.004353740252554,-0.004171027336270,0.000354031304596,-0.018290646374226,-0.000821217661723,0.006388532929122,0.007142609450966) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.050560802221298,0.050078399479389,-0.008414829149842,-0.053955044597387,-0.039049778133631,-0.041398879140615,0.029437225311995,0.073999501764774,-0.043302822858095,-0.017784308642149,0.033554919064045,0.041814967989922,-0.001198710058816,-0.028387058526278,-0.049046222120523,-0.043117854744196) * MODEL5_texOff(vec2(0,0));
res += mat4(-0.006595443934202,-0.013494086451828,-0.017380883917212,0.008288023062050,0.008190754801035,0.005866331048310,0.001209766138345,-0.011104881763458,0.000845713715535,0.007399805355817,0.007644744589925,-0.015612618066370,-0.004259862937033,0.000068239947723,0.003939170390368,0.003367477795109) * MODEL5_texOff(vec2(0,1));
res += mat4(0.013385908678174,0.003775291144848,-0.003367477562279,-0.002392770722508,-0.005666872486472,0.000166974452441,0.003531465074047,0.003010289976373,-0.009268334135413,0.003860786324367,0.009864949621260,0.008669843897223,-0.027012189850211,-0.018198104575276,-0.003905162215233,0.002790019381791) * MODEL5_texOff(vec2(1,-1));
res += mat4(0.003268076339737,-0.016455922275782,-0.014136578887701,0.007732436526567,0.025424316525459,-0.004931237548590,-0.021538916975260,-0.014632844366133,0.019707705825567,0.008411071263254,-0.011947340331972,-0.020448852330446,0.024135714396834,0.018525699153543,-0.002189910039306,-0.024902526289225) * MODEL5_texOff(vec2(1,0));
res += mat4(-0.003951488994062,-0.007288206368685,0.000413362111431,0.011297325603664,-0.004843451082706,-0.008500008843839,-0.000462885043817,0.023349124938250,-0.001612893189304,-0.001941903610714,0.002292972290888,0.013592956587672,-0.005232533905655,-0.006840490270406,-0.002384430030361,0.011972254142165) * MODEL5_texOff(vec2(1,1));
res += mat4(-0.008359817788005,-0.004718694370240,-0.001984235830605,-0.000938346958719,0.002842430258170,0.001587569480762,0.000712658860721,-0.000280862848740,-0.005493140779436,-0.001450336421840,0.001138222170994,0.001787246786989,-0.005854013375938,-0.007056863047183,-0.005409561097622,-0.002209906699136) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.009019439108670,0.000029788619941,-0.006183343008161,-0.006888538599014,-0.003980570938438,-0.003002324374393,0.000691830879077,0.003493062686175,-0.012943919748068,-0.014221531338990,-0.013169381767511,-0.010782988741994,-0.011130427010357,-0.001981443958357,0.004249708261341,-0.000681432604324) * MODEL6_texOff(vec2(-1,0));
res += mat4(-0.000677514821291,0.005654305685312,0.011482043191791,0.010130737908185,-0.002631635172293,-0.001498657278717,0.000620816659648,0.000152957101818,0.002552345860749,0.000447446276667,-0.003517354140058,-0.007884344086051,0.001166294561699,-0.004359172657132,-0.009890122339129,-0.010758313350379) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.003286337014288,-0.003297998104244,-0.008106824010611,-0.009140156209469,0.018794579431415,-0.001988363917917,-0.012401334010065,-0.008355465717614,0.017285326495767,0.006980876903981,0.001913118176162,-0.000735272536986,0.026147753000259,0.009413766674697,0.000371963920770,-0.000950554385781) * MODEL6_texOff(vec2(0,-1));
res += mat4(-0.058775920420885,-0.059890158474445,-0.041286520659924,-0.018430477008224,-0.018172701820731,-0.016366133466363,0.002372133778408,0.024154487997293,0.027404334396124,0.034164678305387,0.032522428780794,0.027966393157840,0.018694391474128,0.038064230233431,0.053080964833498,0.050477657467127) * MODEL6_texOff(vec2(0,0));
res += mat4(0.003770116949454,0.001993804005906,-0.012399920262396,-0.033418662846088,0.008930286392570,0.009915654547513,0.004414919763803,-0.008600898087025,-0.001350666512735,-0.000647706503514,0.003345459466800,0.013755274005234,0.008172699250281,0.007148128002882,0.003635750385001,0.004601609893143) * MODEL6_texOff(vec2(0,1));
res += mat4(0.014528054744005,0.007235092110932,-0.000586275069509,-0.003731523407623,0.009556576609612,-0.003853706875816,-0.011606537736952,-0.010996741242707,-0.013568320311606,0.000043035295676,0.007108879741281,0.007550328504294,0.004358237143606,-0.003436700440943,-0.004483730066568,-0.001718581421301) * MODEL6_texOff(vec2(1,-1));
res += mat4(-0.000377757591195,0.002591713098809,0.010263692587614,0.016712259501219,-0.026919402182102,-0.005782198626548,0.016176909208298,0.020077180117369,-0.023546405136585,-0.035382505506277,-0.039830699563026,-0.033260475844145,0.007101899478585,0.016701782122254,0.018999578431249,0.012318130582571) * MODEL6_texOff(vec2(1,0));
res += mat4(0.005154049023986,0.006895705126226,0.006837418768555,0.004150584805757,0.004910815507174,0.007659022696316,-0.000755403947551,-0.020503493025899,0.003854698501527,0.004011310171336,0.001697857864201,-0.006313626188785,-0.002340645063668,-0.004674924537539,-0.006007536314428,-0.001849537133239) * MODEL6_texOff(vec2(1,1));
#elif (SHARP == 1)
vec4 res = vec4(-0.000105198581878,0.000371108850231,0.000041554972995,-0.000247968273470);
res += mat4(0.000242853449890,-0.002070392947644,-0.004046788439155,-0.002521203365177,-0.004365959204733,-0.001498499885201,0.001802233164199,0.002923557534814,-0.001115595921874,0.002417285693809,0.002304313937202,0.001679170993157,0.009816050529480,0.005660953931510,0.000734702509362,-0.000823256385047) * MODEL4_texOff(vec2(-1,-1));
res += mat4(0.000829058873933,-0.003296714741737,-0.005635152105242,-0.004103436134756,-0.003767637535930,-0.005914602894336,-0.007499331142753,-0.007792715448886,-0.005429946817458,-0.000954995048232,-0.001235583098605,-0.003030673600733,0.009197679348290,0.010943517088890,0.010351964272559,0.010071247816086) * MODEL4_texOff(vec2(-1,0));
res += mat4(0.006336022634059,0.007607066538185,0.004840853158385,0.002486703218892,0.000436087197158,-0.000299801380606,-0.001064473530278,-0.001990962540731,-0.000127372215502,0.001154005876742,-0.001096969470382,-0.005160327535123,0.000985252088867,0.003234745934606,0.004414548631757,0.005350323393941) * MODEL4_texOff(vec2(-1,1));
res += mat4(0.030196269974113,0.009098605252802,-0.005898252129555,-0.007890239357948,0.009799026884139,0.001091131940484,-0.004128911532462,-0.005106970202178,0.017704978585243,-0.002374371746555,-0.010961464606225,-0.009686791338027,0.003057705005631,0.011326784268022,0.010134195908904,0.006759039591998) * MODEL4_texOff(vec2(0,-1));
res += mat4(-0.042034890502691,-0.019275939092040,0.022290030494332,0.043572109192610,0.015980787575245,0.021652732044458,0.022474771365523,0.017761206254363,-0.026010056957603,-0.029209878295660,0.007408313453197,0.031599085777998,-0.033791076391935,-0.041036698967218,-0.038435902446508,-0.021577944979072) * MODEL4_texOff(vec2(0,0));
res += mat4(0.003140710759908,-0.000915306096431,-0.012899768538773,-0.030143532902002,-0.000781070615631,0.001281028729863,0.004934570286423,0.010345374234021,-0.002145873149857,0.010052018798888,0.023389637470245,0.007332837209105,0.009102263487875,0.010703552514315,0.001174519537017,-0.016939833760262) * MODEL4_texOff(vec2(0,1));
res += mat4(-0.000838472740725,-0.000086463231128,-0.001906744088046,-0.002142787212506,-0.016370013356209,-0.004268891178071,0.001123942900449,0.001941424910910,0.003730626776814,-0.005921860225499,-0.008497820235789,-0.006427207496017,0.014269100502133,0.015590954571962,0.011596585623920,0.006381002254784) * MODEL4_texOff(vec2(1,-1));
res += mat4(0.026257660239935,0.026486366987228,0.014259000308812,0.001546491286717,-0.042414195835590,-0.051564890891314,-0.045676745474339,-0.030694317072630,-0.016546152532101,0.002260925481096,0.017531946301460,0.014411705546081,0.000275816535577,-0.003536831587553,-0.002636784221977,0.004557176493108) * MODEL4_texOff(vec2(1,0));
res += mat4(-0.004451034124941,-0.004947533831000,0.000450337858638,0.012988646514714,0.005196256097406,0.002235631691292,-0.009230940602720,-0.025853382423520,0.009042158722878,0.011357928626239,0.000159380913828,-0.016889266669750,0.006922283675522,0.011265097185969,0.010826011188328,0.006477937567979) * MODEL4_texOff(vec2(1,1));
res += mat4(0.003034545108676,-0.001567612751387,-0.002708906074986,-0.002332889940590,0.000396584422560,0.002914341632277,0.005886677186936,0.004566896241158,0.001681609195657,0.001310850726441,0.002416214672849,0.002430372871459,-0.004566309042275,-0.002219180576503,-0.001663700561039,-0.001774868345819) * MODEL5_texOff(vec2(-1,-1));
res += mat4(0.003082519629970,0.003853053785861,0.002947325119749,0.004445067141205,-0.004298996180296,-0.003834752133116,0.002550726523623,0.003006247803569,0.001281428034417,0.002903439570218,0.003252256894484,0.002022017026320,0.003859004704282,0.004148479085416,0.001416696468368,-0.004994862247258) * MODEL5_texOff(vec2(-1,0));
res += mat4(-0.002584643196315,-0.005349664017558,-0.005892899353057,-0.000472510699183,0.000017448217477,-0.002254185266793,-0.000949604844209,-0.001755677512847,0.001409232849255,-0.000451267231256,-0.003008189378306,-0.002711808308959,0.002810513367876,0.004772066604346,0.004791015759110,0.002818272681907) * MODEL5_texOff(vec2(-1,1));
res += mat4(-0.003855923656374,0.015282084234059,0.009875935502350,0.003963042981923,-0.025684732943773,-0.023019816726446,-0.001113134436309,0.005757553037256,0.004888679366559,-0.003625732148066,-0.007411544211209,-0.006643627304584,-0.010799900628626,-0.004611735232174,0.006287654861808,0.006316378246993) * MODEL5_texOff(vec2(0,-1));
res += mat4(0.050073277205229,0.012681304477155,-0.042967304587364,-0.042848154902458,-0.013648684136569,0.021100645884871,0.038005102425814,0.004906337242573,-0.010098373517394,0.001953235361725,0.010158955119550,0.010196259245276,-0.038309976458549,0.017235623672605,0.045261472463608,0.017863642424345) * MODEL5_texOff(vec2(0,0));
res += mat4(-0.006704900413752,-0.014907090924680,-0.006246589124203,0.029701875522733,0.004638202954084,0.007138963788748,-0.002878467785195,-0.018590146675706,0.004160227719694,-0.002279635053128,-0.011792653240263,-0.015449139289558,0.005367813631892,0.011609316803515,-0.006890201941133,-0.042913712561131) * MODEL5_texOff(vec2(0,1));
res += mat4(0.000119015327073,0.002442634897307,0.004707173909992,0.004576399456710,0.011385879479349,-0.002567894523963,-0.007017705589533,-0.003766249865294,0.004496115725487,0.000098772135971,-0.000671841087751,-0.000925653264858,-0.015134812332690,0.008707007393241,0.012576756998897,0.008488371968269) * MODEL5_texOff(vec2(1,-1));
res += mat4(-0.008797783404589,0.013196955434978,0.012938238680363,0.004718659911305,-0.010895364917815,-0.026509797200561,-0.008797575719655,0.013355636037886,0.006449140608311,0.013931084424257,0.016551859676838,0.013911883346736,0.022784303873777,0.011958656832576,-0.018373871222138,-0.033219128847122) * MODEL5_texOff(vec2(1,0));
res += mat4(0.009846087545156,0.006225184071809,-0.014853873290122,-0.026789981871843,-0.001116743893363,0.002940800040960,0.013661542907357,0.012703727930784,-0.001398567226715,-0.005830511916429,-0.009552571922541,-0.006425075698644,-0.005634945351630,-0.005422924645245,0.001409066724591,0.013908114284277) * MODEL5_texOff(vec2(1,1));
res += mat4(0.009250984527171,0.003576160175726,0.000352547271177,-0.001292049884796,0.006886174902320,-0.002614183351398,-0.007810153067112,-0.003561021294445,0.003141343127936,0.000359814293915,-0.001395378378220,-0.002459270181134,-0.005680119618773,0.001021900214255,0.002618584316224,0.000194511565496) * MODEL6_texOff(vec2(-1,-1));
res += mat4(0.002644071355462,0.004156928509474,0.007647667545825,0.010724347084761,-0.000139890282298,-0.000914978270885,0.000709892890882,0.006936913356185,0.006041727494448,0.008593905717134,0.009520060382783,0.007927748374641,-0.007840718142688,-0.008981170132756,-0.007107906509191,-0.004881980363280) * MODEL6_texOff(vec2(-1,0));
res += mat4(0.002058058977127,0.001892847358249,0.000368203938706,0.000389204506064,-0.001639804104343,-0.001515169278719,-0.000683224818204,0.001107589225285,-0.002630952978507,-0.003318565199152,-0.001604956109077,0.002033052500337,-0.002681440440938,-0.004440954420716,-0.005407589022070,-0.006756941787899) * MODEL6_texOff(vec2(-1,1));
res += mat4(-0.001217015902512,0.004970311652869,0.000932644237764,-0.004214359447360,0.053898055106401,0.016952652484179,-0.022212343290448,-0.023086942732334,-0.011583520099521,-0.006329108960927,-0.000252106052358,0.002438566647470,-0.028722725808620,-0.013641336932778,0.000803335802630,0.006446967367083) * MODEL6_texOff(vec2(0,-1));
res += mat4(-0.036497071385384,-0.049493450671434,-0.040319800376892,-0.019774572923779,-0.010827759280801,-0.034198544919491,-0.026284575462341,0.028390673920512,-0.001765887951478,-0.003205267479643,-0.007164718117565,-0.011674910783768,0.026090931147337,0.011451866477728,-0.019444685429335,-0.039123795926571) * MODEL6_texOff(vec2(0,0));
res += mat4(-0.002760652918369,0.001463299151510,0.001222563441843,-0.010788792744279,0.004558476153761,0.004577599000186,0.002755579771474,-0.000517775246408,-0.001009929343127,-0.003316894406453,-0.004066868685186,-0.002198719885200,-0.004751111846417,-0.004239749629050,0.003978126682341,0.016672285273671) * MODEL6_texOff(vec2(0,1));
res += mat4(-0.013165029697120,-0.005295898765326,-0.001424646470696,-0.000447529222583,-0.005756983533502,-0.018164187669754,-0.009201833978295,0.005456173792481,0.023285996168852,0.008253061212599,0.000865019916091,0.000499127781950,0.008874634280801,0.000303958513541,-0.001408578245901,-0.000495353189763) * MODEL6_texOff(vec2(1,-1));
res += mat4(0.006027314346284,-0.004761953372508,-0.014412796124816,-0.016895309090614,-0.005146325565875,-0.005584320984781,0.002623404609039,0.007645646575838,0.046206668019295,0.064729683101177,0.064306996762753,0.047063503414392,-0.001802180195227,0.011326360516250,0.020947674289346,0.020277338102460) * MODEL6_texOff(vec2(1,0));
res += mat4(-0.002232255646959,0.000681430625264,0.005498266313225,0.006702479440719,0.002347212983295,0.004264534451067,0.003772196127102,0.001059030648321,0.001829496002756,0.000023395034077,0.004847127944231,0.020142765715718,0.001911052851938,-0.003440744243562,-0.007177087944001,-0.006872693076730) * MODEL6_texOff(vec2(1,1));
#endif

return res;
}

//!HOOK LUMA
//!WHEN OUTPUT.w LUMA.w 3.200 * > OUTPUT.h LUMA.h 3.200 * > *
//!WIDTH LUMA.w 4 *
//!HEIGHT LUMA.h 4 *
//!BIND SUBCONV1
//!BIND SUBCONV2
//!BIND SUBCONV3
//!BIND SUBCONV4
//!BIND LANCZOS3
//!DESC [AiUpscale_Fast_4x_Photo_RT] depth to space

vec4 hook()
{
vec2 fcoord = fract(SUBCONV1_pos * SUBCONV1_size);
vec2 base = SUBCONV1_pos + (vec2(0.5) - fcoord) * SUBCONV1_pt;
ivec2 index = ivec2(fcoord * vec2(4));
mat4 res = mat4(SUBCONV1_tex(base),SUBCONV2_tex(base),SUBCONV3_tex(base),SUBCONV4_tex(base));
return vec4(res[index.x][index.y] + float(LANCZOS3_texOff(0)), 0, 0, 1);
}
